17.3.1. Using Test Suite - 5.2 English - 57404

AOCL User Guide (57404)

Document ID
57404
Release Date
2025-12-29
Version
5.2 English

The AOCL-Sparse library comes with a comprehensive set of tests which you might want to run when you build the library from source (refer to Building from Source on Linux and Building from Source on Windows). During the configuration, enable BUILD_UNIT_TESTS, BUILD_CLIENTS_BENCHMARKS and BUILD_CLIENTS_SAMPLES. CMake will then generate all unit tests, examples, and a selection of benchmarking tests using CMake’s ctests framework. The tests can be executed from the command prompt as follows:

$ cd <build_directory>
$ ctest -VV

Refer to the CTest help to learn about all the possible ways to trigger an individual test or a specific selection.

Note

From 5.1, unit tests can be built out of source tree. Refer to README.md in tests/unit_tests.