Skip to content

Automated performance test for BHE soil element assembly cache

Christoph Lehmann requested to merge chleh/ogs:non-fct-test into master

This MR adds a performance test using pytest. It might serve as a blueprint for further automated performance tests (e.g. whether OpenMP parallelization is effective)

Test locally. E.g.:

$ pytest -ra -k test_bhe_assembly_matrix_cache_soil_elements
================================================ test session starts ================================================
platform linux -- Python 3.13.1, pytest-8.2.2, pluggy-1.5.0
rootdir: /home/lehmannc/prog/ogs6/alt/ogs
configfile: pyproject.toml
testpaths: Tests
plugins: typeguard-4.4.1, anyio-3.7.1
collected 57 items / 56 deselected / 1 selected                                                                     

Tests/Python/test_bhe_assembly_matrix_cache_soil_elements.py F                                                [100%]

===================================================== FAILURES ======================================================
____________________________________________ test_assembly_optimization _____________________________________________
...

or

$ OGS_PERFORMANCE_TESTS_ALLOWED_TO_FAIL=true pytest -ra -k test_bhe_assembly_matrix_cache_soil_elements
================================================ test session starts ================================================
platform linux -- Python 3.13.1, pytest-8.2.2, pluggy-1.5.0
rootdir: /home/lehmannc/prog/ogs6/alt/ogs
configfile: pyproject.toml
testpaths: Tests
plugins: typeguard-4.4.1, anyio-3.7.1
collected 57 items / 56 deselected / 1 selected                                                                     

Tests/Python/test_bhe_assembly_matrix_cache_soil_elements.py x                                                [100%]

===================================================== XFAILURES =====================================================
____________________________________________ test_assembly_optimization _____________________________________________
...
  1. Feature description was added to the changelog
  2. Tests covering your feature were added?
  3. Any new feature or behaviour change was documented?
Edited by Christoph Lehmann

Merge request reports

Loading