Skip to content

Latest commit

 

History

History
37 lines (24 loc) · 1.19 KB

File metadata and controls

37 lines (24 loc) · 1.19 KB

Tests

These tests verify that the experiment scripts produce numerically identical results (within floating-point tolerance) compared to a stored reference run.

All tests use CI=1 mode, which exercises the full code paths but with reduced problem sizes (runs in minutes rather than hours).

Running Tests

The tests can be executed with

pytest -v

after setting up an environment (see the getting started section in the README.md).

Generating Expected Results

Expected outputs live in tests/expected_output/ and are checked into git. To regenerate them (e.g. after an intentional change to the numerics) in an active environment (see the getting started section in the README.md),

  1. Run the tests natively (see above) or with

    CI=1 docker compose -f docker/docker-compose.yml run --rm dev pytest -v

    in dockerised mode (see the getting started section in the README.md) to populate tests/actual_output.

  2. Record the actual results as the expected ones by running:

    bash tests/update_expected_output_from_actual_output.bash