Hanselminutes with Scott Hanselman cover image

The Art of Unit Testing with Roy Osherove

Hanselminutes with Scott Hanselman

00:00

How to Write a Positive Test

I usually start with one to one and I start with the mapping of, well if I test a method, I start with a test method. But at some point you might realize that you are writing a lot of tests just for one method. Or you would go further and say I have a class for a specific scenario for a product then it no longer maps to a specific class. It just maps to specific scenarios on the whole product and then checks multiple classes at the same time. The question is when do you read the test already before or after the method?

Play episode from 27:27
Transcript

The AI-powered Podcast Player

Save insights by tapping your headphones, chat with episodes, discover the best highlights - and more!
App store bannerPlay store banner
Get the app