📄️ No tests
From time to time you'll encounter a codebase with no tests at all.
📄️ Code coverage
Sometimes when there's a poor test discipline, teams add a code coverage test to ensure a minimum percentage of code is covered by tests.
📄️ Plain assert
The built-in assert keyword in Java is a very basic mechanism for checking assumptions in code.
📄️ Poor expressiveness
Tests should clearly convey their intent.
📄️ Backwards
Between JUnit 4 and JUnit 5 the order of arguments in assertions was swapped to improve readability.
📄️ Redundant assertions
Sometimes overlapping assertions are used in sequence, where one would imply the other.
📄️ Try/Catch fail
Using try/catch blocks with fail() calls to test for exceptions is an awkward outdated pattern.
📄️ AssertThrows verify
Sometimes tests aren't quite as they seem. This is one of those cases.