Skip to content
Snippets Groups Projects
Commit 7855ae68 authored by Soeren Peters's avatar Soeren Peters
Browse files

Change output folder name. Remove colon from CI jobs.

parent f932ef3e
No related branches found
No related tags found
1 merge request!218dynamically create CI pipeline for regression tests.
......@@ -261,7 +261,7 @@ build-regression-tests-ci:
needs: []
trigger:regression-tests:
trigger-regression-tests:
stage: test
needs:
- build-regression-tests-ci
......
......@@ -13,9 +13,8 @@ download_reference_data () {
# 1. REFERENCE_DATA_DIR - to download the reference data and compare against
# 2. CMAKE_FLAGS - cmake flags for the build of VirtualFluids
# 3. APPLICATION - the application to be executed
# 4. PATH_TO_DIR - the path to the produced data to be compared
# 4. RESULT_DATA_DIR - the path to the produced data to be compared
run_regression_test () {
download_reference_data $1
rm -rf build && mkdir -p build
......@@ -27,5 +26,4 @@ run_regression_test () {
# execute fieldcompare (A more comprehensive manual can be found here https://gitlab.com/dglaeser/fieldcompare)
fieldcompare dir $4 reference_data/$1 --include-files "*.vtu"
}
\ No newline at end of file
......@@ -12,8 +12,8 @@ CMAKE_FLAGS="--preset=make_gpu -DCMAKE_BUILD_TYPE=Release -DCMAKE_CUDA_ARCHITECT
APPLICATION=./build/bin/DrivenCavity
# 4. set the path to the produced data
PATH_TO_DIR=output/DrivenCavity
RESULT_DATA_DIR=output/DrivenCavity
run_regression_test "$REFERENCE_DATA_DIR" "$CMAKE_FLAGS" "$APPLICATION" "$PATH_TO_DIR"
run_regression_test "$REFERENCE_DATA_DIR" "$CMAKE_FLAGS" "$APPLICATION" "$RESULT_DATA_DIR"
......@@ -13,7 +13,7 @@ CMAKE_FLAGS="--preset=make_gpu -DCMAKE_BUILD_TYPE=Release -DCMAKE_CUDA_ARCHITECT
APPLICATION=./build/bin/DrivenCavityUniform
# 4. set the path to the produced data
PATH_TO_DIR=output/DrivenCavity_uniform
RESULT_DATA_DIR=output/DrivenCavity_uniform
run_regression_test "$REFERENCE_DATA_DIR" "$CMAKE_FLAGS" "$APPLICATION" "$PATH_TO_DIR"
run_regression_test "$REFERENCE_DATA_DIR" "$CMAKE_FLAGS" "$APPLICATION" "$RESULT_DATA_DIR"
from dataclasses import dataclass
from jinja2 import Template
from pathlib import Path
......@@ -6,7 +5,7 @@ TEMPLATES_DIR = Path(__file__).parent
REGRESSION_CI_TEMPLATE = TEMPLATES_DIR / "regression-tests-ci.yml.j2"
GENERATED_DIR = Path("generated")
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:
......@@ -15,13 +14,7 @@ def build_regression_job_string(regression_tests: list[str]) -> str:
def main():
root_dir = "regression-tests"
root_dir_instance = Path(root_dir)
regression_tests_files = [item.stem for item in root_dir_instance.glob("*_test.sh")]
print(regression_tests_files)
regression_tests_files = [item.stem for item in TEST_FILE_DIR.glob("*_test.sh")]
regression_tests_ci_file = build_regression_job_string(regression_tests_files)
REGRESSION_CI_FILE.write_text(regression_tests_ci_file)
......
......@@ -17,7 +17,7 @@ stages:
- pip install fieldcompare
{% for regression_test in regression_tests %}
regression-test:{{ regression_test }}:
run-regression-test-{{ regression_test }}:
extends: .regression-test
script:
......
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