Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#178: added support for assertSoftly #185

Merged
merged 5 commits into from
Dec 27, 2020

Conversation

drcolombo
Copy link
Contributor

Added support for assertSoftly notation (#178 ) based on the logic from Kotest

@drcolombo
Copy link
Contributor Author

No idea how SonarCloud verifies the coverage, but locally UserStackTraceConverter.kt is covered for 100% (methods and lines) and in stacktraces.kt 100% of methods are covered and 80% of lines...
Screenshot 2020-11-17 155058

@MarkusAmshove
Copy link
Owner

MarkusAmshove commented Nov 21, 2020

Thank you for the PR, this looks really useful and I'm willing to merge it!

I'm a bit hesitant on the "based on the logic from Kotest" part, do you know which parts/files you've taken from Kotest so we can add the proper attribution in the README? Kotest has the Apache license, so it should be fine to add the proper attribution and use it (I can do it after the merge if I know which files are based or copied from Kotest) :-)

@drcolombo
Copy link
Contributor Author

drcolombo commented Nov 22, 2020

which parts/files you've taken from Kotest so we can add the proper attribution in the README? Kotest has the Apache license, so it should be fine to add the proper attribution and use it (I can do it after the merge if I know which files are based or copied from Kotest) :-)

  1. ErrorCollector.kt and StackTraces.kt in all 3 modules
  2. UserStackTraceConverter.kt
    I've copied these files from Kotest almost without changes (just cosmetic ones have been added and some refactoring so their code would be compatible with Kluent).
    I've also moved all tests from org.amshove.kluent into org.amshove.kluent.tests package, as the logic within StackTraces that removes stacktrace items related to the Kluent code from the stack relies on the namespace.

@drcolombo
Copy link
Contributor Author

Tomorrow I'll provide additional code changes (didn't notice that kotlin.test.assert* were still used internally in Kluent) and updated documentation. So please, do not merge until further notice 😉

… internally implemented within Kluent to support assertSoftly notation;

2. Updated/fixed code and tests for JS and NATIVE;
3. Added documentation (docs/SoftlyAssertions.md) describing the assertSoftly notation.
@drcolombo drcolombo closed this Dec 21, 2020
@drcolombo drcolombo reopened this Dec 21, 2020
@sonarcloud
Copy link

sonarcloud bot commented Dec 21, 2020

SonarCloud Quality Gate failed.

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

12.8% 12.8% Coverage
0.0% 0.0% Duplication

warning The version of Java (1.8.0_275) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 11.
Read more here

@MarkusAmshove MarkusAmshove merged commit d3dfbea into MarkusAmshove:master Dec 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants