Good Unit Test Qualities

  • Repeatable
    Unit tests should be repeatable. If a test fails, it should always fail, if it succeed, it should always be.
    Good unit tests also repeatable all the time, not succeed at certain time, but fail at other times.
  • Independent
    Each unit test should be independent, meaning it should not depend on other unit test for it to run.
    You should also be able to run each unit test by itself, or a select group of tests.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s