aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/source/test_travis_matrix.sh
diff options
context:
space:
mode:
authorGravatar MaxThevenet <mthevenet@lbl.gov> 2020-02-24 14:42:41 -0800
committerGravatar GitHub <noreply@github.com> 2020-02-24 14:42:41 -0800
commit8c3523a1054a0d7591cac951aa723f2b01c8e68d (patch)
tree19fef83fb706b5161f98a6de3cdfdbd5069f31a1 /.github/workflows/source/test_travis_matrix.sh
parent7ed7f58a768dbeb72ca1bc269657af8b7b2e19b0 (diff)
downloadWarpX-8c3523a1054a0d7591cac951aa723f2b01c8e68d.tar.gz
WarpX-8c3523a1054a0d7591cac951aa723f2b01c8e68d.tar.zst
WarpX-8c3523a1054a0d7591cac951aa723f2b01c8e68d.zip
Split travis tests in bigger matrix (#723)
* split travis tests in bigger matrix * split more TravisCI tests, add electrostatic, use defaults values * typo * need to split psatd too * consistent variable names and use function to avoid duplication * fix typo for qed tests * typo * also need to update run_tests.sg * change matrix * try gathering 2D and 3D tests together * split test matrix to have 2 compilations for each group * EOL * avoid compiling electrostatic * typo * [ci skip] Update Regression/prepare_file_travis.py Co-Authored-By: Axel Huebl <axel.huebl@plasma.ninja> * this is an OR, not an AND * test that TravisCI matrix encompasses all tests * debugging * debugging * should fix the error * Apply suggestions from code review Co-Authored-By: Axel Huebl <axel.huebl@plasma.ninja> * use fewer && * safeguard * should work like that Co-authored-by: Axel Huebl <axel.huebl@plasma.ninja>
Diffstat (limited to '.github/workflows/source/test_travis_matrix.sh')
-rwxr-xr-x.github/workflows/source/test_travis_matrix.sh36
1 files changed, 36 insertions, 0 deletions
diff --git a/.github/workflows/source/test_travis_matrix.sh b/.github/workflows/source/test_travis_matrix.sh
new file mode 100755
index 000000000..400970c54
--- /dev/null
+++ b/.github/workflows/source/test_travis_matrix.sh
@@ -0,0 +1,36 @@
+#! /usr/bin/env sh
+
+set -e
+
+cp .github/workflows/source/travis_matrix.py Regression/
+cd Regression/
+
+# Put the name of all travis tests into a text file
+python prepare_file_travis.py
+grep "\[" travis-tests.ini > travis_all_tests.txt
+
+# Concatenate the names of all elements in Travis matrix into another test file
+WARPX_CI_REGULAR_CARTESIAN=TRUE python prepare_file_travis.py
+grep "\[" travis-tests.ini > travis_matrix_elements.txt
+WARPX_CI_PSATD=TRUE python prepare_file_travis.py
+grep "\[" travis-tests.ini >> travis_matrix_elements.txt
+WARPX_CI_PYTHON_MAIN=TRUE python prepare_file_travis.py
+grep "\[" travis-tests.ini >> travis_matrix_elements.txt
+WARPX_CI_SINGLE_PRECISION=TRUE python prepare_file_travis.py
+grep "\[" travis-tests.ini >> travis_matrix_elements.txt
+WARPX_CI_RZ_OR_NOMPI=TRUE python prepare_file_travis.py
+grep "\[" travis-tests.ini >> travis_matrix_elements.txt
+WARPX_CI_QED=TRUE python prepare_file_travis.py
+grep "\[" travis-tests.ini >> travis_matrix_elements.txt
+
+# Check that the resulting lists are equal
+{
+ python travis_matrix.py &&
+ rm travis_all_tests.txt travis_matrix_elements.txt travis_matrix.py &&
+ echo "test passed" &&
+ exit 0
+} || {
+ rm travis_all_tests.txt travis_matrix_elements.txt travis_matrix.py &&
+ echo "tests failed" &&
+ exit 1
+}