Unit Test Warning

Just because a test fails it does not mean that the code is wrong.

I found a javascript ui test that was failing for changes that could not be caused by user input. The test api could introduce data in a manner that the ui does not permit. In this case the test was wrong.

In general a failing test can reveal:

– The code is wrong

– The test is wrong

– They are both wrong

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 )

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