O'Reilly logo

Quality Code: Software Testing Principles, Practices, and Patterns by Stephen Vance

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Keep It Simple: Remove Code

You can simplify your tests and reduce your testing burden by deleting code. If the code does not exist, you neither have to test it nor have to maintain it. Remove unused code, commented code, code that does more than it needs to, and code that is more complex than it needs to be. Deleting code is a great way to reduce your costs.

Also, remove redundant tests. Even better, do not write them to begin with. Extra tests do not add to your validation, but they take time to run and attention to maintain. Just imagine how much time could be wasted trying to figure out what makes the redundant test different from the other tests in the same area.

If you use code coverage to guide your testing, removing code also increases ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required