Commit 49ccd33c authored by Dennis Gläser's avatar Dennis Gläser Committed by Dennis
Browse files

[ci] do test selection also for mrs in lecture

parent 34294ef2
......@@ -21,6 +21,8 @@ variables:
when: manual
variables:
DUMUX_MR_BRANCH: $DUMUX_MERGE_REQUEST_BRANCH
TRIGGER_SOURCE: $CI_PIPELINE_SOURCE
MR_TARGET_BRANCH_NAME: $CI_MERGE_REQUEST_TARGET_BRANCH_NAME
full-dune-2.7-gcc:
extends: .default-trigger
......
......@@ -10,6 +10,10 @@ workflow:
rules:
- if: $CI_PIPELINE_SOURCE=="parent_pipeline"
variables:
TRIGGER_SOURCE: "unknown"
MR_TARGET_BRANCH_NAME: "master"
select tests:
stage: configure
before_script:
......@@ -26,8 +30,13 @@ select tests:
- |
dunecontrol --opts=$DUNE_OPTS_FILE --current all
if [[ -n "${DUMUX_MR_BRANCH}" ]]; then
python3 dumux/bin/testing/getchangedfiles.py -o changedfiles.txt -t origin/$DUMUX_MR_BRANCH
python3 dumux/bin/testing/findtests.py -o affectedtests.json --file-list changedfiles.txt
echo "Detecting test affected by changes in Dumux"
python3 dumux/bin/testing/getchangedfiles.py -f dumux -o changedfiles.txt -t origin/$DUMUX_MR_BRANCH
python3 dumux/bin/testing/findtests.py -o affectedtests.json --file-list changedfiles.txt --build-dir build-cmake
elif [[ "$TRIGGER_SOURCE" == "merge_request_event" ]]; then
echo "Detecting test affected by changes in this merge request, using target branch $MR_TARGET_BRANCH_NAME"
python3 dumux/bin/testing/getchangedfiles.py -o changedfiles.txt -t origin/$MR_TARGET_BRANCH_NAME
python3 dumux/bin/testing/findtests.py -o affectedtests.json --file-list changedfiles.txt --build-dir build-cmake
else
echo "Skipping test selection, build/test stages will consider all tests!"
echo "{}" >> affectedtests.json
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment