Book Image

Node.js High Performance

By : Diogo Resende
Book Image

Node.js High Performance

By: Diogo Resende

Overview of this book

Table of Contents (14 chapters)

Chapter 6. Test, Benchmark, and Analyze

Testing your application is as important as its development. Testing is the process of analyzing your application modules and the application as a whole to see whether it behaves as you expect it. It allows your business to define use cases and check whether they're all accomplished.

There are many testing techniques. One of the most famous is Test-driven Development (TDD). This technique consists of using the smallest development cycles possible. Between every cycle, tests are performed and new tests and uses cases are added before they're developed. This way, your application versions can be continuously tested and any faulty version can be quickly spotted. If you use a version control system, such as Git, it becomes very easy to find the culprit of the failing test and fix it.

An important aspect of performing tests from the ground up is that you can keep adding use cases and test cases as you spot them. For example, if someone reports a bug and you...