Testing on the Simulator
The Test Configurations provided with C++test are prepared for testing on the simulator using the semi-hosting feature.
To enable this, add the IOPORT address to the linker command line. For example:
This additional option should be specified in the linker options within the C++test Build Settings (right-click that project in the project tree, choose Properties from the shortcut menu, then select choose Parasoft> C++test> Build Settings).
The INIT section defined in the RAM area is required for unit testing. Refer to the SOFTUNE manual for instructions.
Customizing Built-in Test Configurations
The Test Configurations provided to execute runtime tests for FR Softune projects (“Builtin> Embedded Systems> Spansion FR Softune”) may require environment-specific customization. The typical customizations are done with the help of test flow definition properties that are listed for each Test Configuration (in the Execution> General tab, "Execution details" section).
The table below describes the test flow properties for the dedicated FR Softune built-in Test Configuration, which is named "Run Spansion FR Softune Tests - Simulator":
|Exit Point||__exit||Exit point of the application. This is the point at which the simulator will end the execution.|
Directory Path for Test Executable
|The text executable will be generated in this location. Usually, this should be the same location as the original binary.|
The Run Spansion FR Softune Tests - Simulator Test Configuration is provided to facilitate the unit testing process.
To run unit testing on the simulator:
- Manually create or automatically generate a set of test cases.
- Duplicate the FR Softune unit test configuration.
- Modify the Test Configuration as needed.
- See Customizing Built-in Test Configurations for details.
- Select the desired testing context.
- Run tests with the customized Test Configuration created above.
Debugging Test Cases
Use External Embedded debugging mode. For more details see: