lundi 29 décembre 2014

Should I have failing tests?

Please note: I'm not asking for your opinion. I'm asking about conventions.


I was just wondering whether I should have both passing and failing tests with appropriate method names such as, Should_Fail_When_UsageQuantityIsNegative() , Should_Fail_When_UsageQuantityMoreThan50() , Should_Pass_When_UsageQuantityIs50().


Or instead should I code them to pass and keep all the tests in Passed condition?


Thanks! Cheers!


Aucun commentaire:

Enregistrer un commentaire