You've already forked gnatstudio
mirror of
https://github.com/AdaCore/gnatstudio.git
synced 2026-02-12 12:42:33 -08:00
GPS testsuite
Writing tests
Tests are in the directory tests, with one subdirectory per test.
Each test should contain:
- a
test.pyfile, which is loaded by GPS. - a
test.yamlfile which contains metadata needed to run the test.
As an example, look at the following tests:
tests/minimal- this test contains the minimal test framework: copy this to start a new testtests/Z999-999.xfail- this test contains a test which is expected to fail.
To test for functionality, use the GPS scripting API, and in particular make use
of gs_utils.internal.utils.gps_assert:
gps_assert(something_observed, something_expected, "message to emit")
Running tests
To run the entire testsuite:
./run.sh
To run one individual test pass its directory as parameter:
./run.sh tests/minimal/
The complete results are in the out/ directory.