Assertion Messages
We will learn about assertion messages and why we shouldn’t use them.
Assertion messages are code comments to improve test readability. All JUnit assert forms (classic
, fail()
, and assertThat()
) support an optional first argument named message
.
The message allows us to supply a verbose explanation of the rationale behind the assertion()
in ...
Access this course and 1400+ top-rated courses and projects.