5min chapter

Coding Blocks cover image

Errors vs Exceptions, Reddit Rebels, and the 2023 StackOverflow Survey

Coding Blocks

CHAPTER

The Importance of Multiple Assertions in Unit Testing

In Vladimir's book, he makes the point that multiple asserts are okay as long as they're part of the same behavior. So if you're asserting before that still should be a code smell, right? He convinced me that like having multiple asserts in your test is OK. But he also makes this strong case for either writing your methods in a fluent style or using a library that lets you do a fluent style syntax. And we will have a link in the show and that is an affiliate link. We will get a little tiny change from it. If you haven't checked out this book, you know, there's no need to buy it yet but go check it out!

00:00

Get the Snipd
podcast app

Unlock the knowledge in podcasts with the podcast player of the future.
App store bannerPlay store banner

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode

Save any
moment

Hear something you like? Tap your headphones to save it with AI-generated key takeaways

Share
& Export

Send highlights to Twitter, WhatsApp or export them to Notion, Readwise & more

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode