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

refactor: AssertJ best practices #3637

Merged

Conversation

timtebeek
Copy link
Contributor

Continuation of #3630 (comment)

This mostly

  • replaces assertTrue with assertThat for more helpful failure messages
  • replaces org.junit.jupiter.api.Assertions.assertThrows with org.assertj.core.api.AssertionsForClassTypes.assertThatExceptionOfType

Use this link to re-run the recipe: https://app.moderne.io/recipes/org.openrewrite.java.testing.assertj.Assertj

timtebeek and others added 2 commits December 13, 2023 08:43

Verified

This commit was signed with the committer’s verified signature. The key has expired.
MylesBorins Myles Borins
Use this link to re-run the recipe: https://app.moderne.io/recipes/org.openrewrite.java.testing.assertj.Assertj

Co-authored-by: Moderne <team@moderne.io>
Copy link
Member

@codefromthecrypt codefromthecrypt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

happy with this. the test flake will ideally be disappearing soon as well.

@codefromthecrypt codefromthecrypt merged commit 6d6ba01 into openzipkin:master Dec 13, 2023
@timtebeek timtebeek deleted the refactor/assert-j-best-practices branch December 13, 2023 09:19
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.

None yet

2 participants