Skip to content
Snippets Groups Projects
Commit ffe96914 authored by Sören Peters's avatar Sören Peters
Browse files

Merge branch 'feature/directories-for-regression-tests' into 'develop'

Feature/directories for regression tests

See merge request irmb/VirtualFluids_dev!342
parents 34f1c033 19111e9a
No related branches found
No related tags found
1 merge request!342Feature/directories for regression tests
Pipeline #33585 canceled
Showing
with 10 additions and 7 deletions
......@@ -8,16 +8,19 @@ REGRESSION_CI_FILE = GENERATED_DIR / "regression-tests-ci.yml"
TEST_FILE_DIR = Path("regression-tests")
def build_regression_job_string(regression_tests: list[str]) -> str:
def build_regression_job_string(regression_tests: list[(str,str)]) -> str:
template = Template(REGRESSION_CI_TEMPLATE.read_text())
return template.render(regression_tests=regression_tests)
def trim_parent_path(name: str) -> str:
return name.replace(str(TEST_FILE_DIR)+"/", "")
def main():
regression_tests_files = [item.stem for item in TEST_FILE_DIR.glob("*_test.sh")]
regression_tests_files = [(item.stem, trim_parent_path(str(item.parent))) for item in TEST_FILE_DIR.rglob("*_test.sh")]
print(regression_tests_files)
regression_tests_ci_file = build_regression_job_string(regression_tests_files)
REGRESSION_CI_FILE.write_text(regression_tests_ci_file)
if __name__ == "__main__":
GENERATED_DIR.mkdir(parents=True, exist_ok=True)
main()
\ No newline at end of file
main()
image: git.rz.tu-bs.de:4567/irmb/virtualfluids/ubuntu22_04:1.0
image: git.rz.tu-bs.de:4567/irmb/virtualfluids/ubuntu22_04:1.1
stages:
- test
......@@ -13,7 +13,7 @@ stages:
- linux
before_script:
- chmod +x ./regression-tests/*
- chmod -R +x ./regression-tests/*
- pip install fieldcompare
artifacts:
......@@ -23,10 +23,10 @@ stages:
when: on_failure
{% for regression_test in regression_tests %}
run-regression-test-{{ regression_test }}:
run-regression-test-{{ regression_test[1] }}-{{ regression_test[0] }}:
extends: .regression-test
script:
- ./regression-tests/{{ regression_test }}.sh
- ./regression-tests/{{ regression_test[1] }}/{{ regression_test[0] }}.sh
{% endfor %}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment