We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
There's a value in shipping Kotlin-friendly API by default.
See https://github.com/junit-team/junit5/blob/main/junit-jupiter-api/src/main/kotlin/org/junit/jupiter/api/Assertions.kt
For example, the current SoftAssertions syntax is
SoftAssertions
SoftAssertions.assertSoftly { softly -> // ... softly.assertThat(...).isEqualTo(...) // ... softly.assertAll() }
The issue is that it is verbose, and the user might fail to call assertAll.
assertAll
A better variation would be
assertSoftly { assertThat(...).isEqualTo(...) // no need to call assertAll, it would be automatic }
That is achievable with a small helper:
fun assertSoftly(body: SoftAssertions.() -> Unit) = SoftAssertions.assertSoftly(body)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Feature summary
There's a value in shipping Kotlin-friendly API by default.
See https://github.com/junit-team/junit5/blob/main/junit-jupiter-api/src/main/kotlin/org/junit/jupiter/api/Assertions.kt
For example, the current
SoftAssertions
syntax isThe issue is that it is verbose, and the user might fail to call
assertAll
.A better variation would be
That is achievable with a small helper:
The text was updated successfully, but these errors were encountered: