~/talk

Better Assertions with AssertJ

Talkat JCON EUROPE 2026 · 2026-04-20..04-23· [testing, java]
slides:none on file

Shows how AssertJ fluent chaining and features like recursive comparison, .actual(), custom domain assertions, and soft assertions produce far clearer failure messages than plain JUnit or Hamcrest. Demonstrates automated migration paths: JUnit4/Vintage → JUnit Jupiter/JUnit 6 and Hamcrest → AssertJ, plus Spring MVC Hamcrest conversions. Uses tooling—OpenRewrite recipes driven by Google Error Prone-style templates—with 1,000+ automated rules that run in roughly a single compile cycle to apply safe, project-wide assertion upgrades.

AI-written summary · about

  1. 0:00Introduction and motivation
  2. 3:46Live demo setup
  3. 5:58Problems with missing tests
  4. 6:19Outdated assertion patterns
  5. 13:01Legacy test structures
  6. 16:51Hamcrest vs modern assertions
  7. 20:43AssertJ features and benefits
  8. 25:13Advanced AssertJ techniques
  9. 31:11Soft assertions explained
  10. 34:21Automated migration to AssertJ
  11. 37:09Spring and AssertJ integration
  12. 38:33Sustaining test quality
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.