31. Upsides and Downsides
●
need to write them
●
can hide bad smells
●
readable
●
reusable
●
simple to write
●
cheap to maintain
32. Best Practices
use AssertJ
• forget about JUnit/TestNG assertions
introduce custom assertions
• when private methods are not good
enough
• if you care about ubiquitous language
• when “then” part is getting huge
• to impress/confuse your team mates
36. Thank you!
You can learn more about
writing high quality tests by
reading my books:
„Practical Unit Testing”
and
„Bad Tests, Good Tests”.
Please visit
http://practicalunittesting.com
to learn more.