-
Notifications
You must be signed in to change notification settings - Fork 10
Testing Unit Tests
Unit Testing is a level of software testing where individual units/ components of a software are tested. The objective of Unit Testing is to isolate a section of code and verify its correctness.
Ideally, each test case is independent from the others. Substitutes such as method stubs, mock objects, and spies can be used to assist testing a module in isolation. These topics will be covered in more detail in the Sinon section.
Mocha Testing framework is used in this project to write integration tests.
-
Unit testing increases confidence in changing/ maintaining code. If good unit tests are written and if they are run every time any code is changed, we will be able to promptly catch any defects introduced due to the change. Also, if codes are already made less interdependent to make unit testing possible, the unintended impact of changes to any code is less.
-
Codes are more reusable. In order to make unit testing possible, codes need to be modular. This means that codes are easier to reuse.
-
Development is faster. If you do not have unit testing in place we might have to manually test some functionalities of the code. But unit tests enable us to automatically test different scenarios.
-
The cost, in terms of time, effort and money, of fixing a defect detected during unit testing is lesser in comparison to that of defects detected at higher levels.
- Autolabcli v1.0.0 Docs
- Submission Workflow
- Architecture
- Refactoring Advice
- Feature Development
- Autolabcli Tests
- Events Doc
- Sequence Diagrams
- Testing in Javascript
- Libraries
- Debug Techniques
- Arrow Functions
- Autolabcli v0.1.1 Docs
- References