Skip to content

AWS, Core: Replace .withFailMessage() usage with .as()#10000

Merged
nastra merged 1 commit into
apache:mainfrom
nastra:replace-with-fail-msg-usage
Mar 19, 2024
Merged

AWS, Core: Replace .withFailMessage() usage with .as()#10000
nastra merged 1 commit into
apache:mainfrom
nastra:replace-with-fail-msg-usage

Conversation

@nastra
Copy link
Copy Markdown
Contributor

@nastra nastra commented Mar 19, 2024

We almost never want to use .withFailMessage() as that will override any enriched contextual information that AssertJ generally provides about actual/expected. It's better to use .as() to add some description to the check being done, which allows to still show contextual information about actual/expected if the assertion ever fails.

We almost never want to use `.withFailMessage()` as that will override
any enriched contextual information that AssertJ generally provides
about actual/expected. It's better to use `.as()` to add some
description to the check being done, which allows to still show
contextual information about actual/expected if the assertion ever
fails.
@nastra nastra merged commit f425dc7 into apache:main Mar 19, 2024
@nastra nastra deleted the replace-with-fail-msg-usage branch March 19, 2024 16:05
zachdisc pushed a commit to zachdisc/iceberg that referenced this pull request Dec 23, 2024
We almost never want to use `.withFailMessage()` as that will override
any enriched contextual information that AssertJ generally provides
about actual/expected. It's better to use `.as()` to add some
description to the check being done, which allows to still show
contextual information about actual/expected if the assertion ever
fails.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants