
Unit and integration testing is the process testing portions of a software application, prior to full system testing. Unit and integration testing is an important part of building a robust and error free application, because it allows the tester to more easily stimulate the low-level functionality of the application, and prove that the low-level requirements have been implemented properly.
Unit and integration testing is generally performed by developers as the code is built. As individual software components are created, test code is generated to take the place of the external interfaces of the code under test. This test code, generally called a test harness, consists of drivers to stimulate the functions of the code being tested, and stubs to take the place of functions called by the code being tested, that may not yet be complete
The VectorCAST tools for unit and integration testing, are available for VectorCAST/C++ and VectorCAST/Ada. Both tools automate the key activities associated with software testing, including the generation of a complete executable test harnesses, the management of test cases and test results, and the automation of regression testing.
The executable harness generated by the VectorCAST, consists of a test driver, the source file(s) under test, complete stubs for dependent functions, and the source files for any dependent units that are not stubbed. The test harness is data-driven, meaning test data is read by the harness during execution. This approach precludes the need of having to compile and link a new executable harness each time a new test is created.
There are two goals of unit and integration testing:
- To generate test cases to prove that the code is implemented properly. This requires test cases consisting of known input and expected values, to stimulate the functionality of the code under test.
- To prove that the testing has been thorough. This requires tracking code coverage to prove that the test cases that have been run, have resulted in 100% of the underlying application code being executed.
VectorCAST automates both of these tasks, and more importantly, allows for the completely automatic regression testing of your application, over the entire lifecycle.