Allow useful CI to run in forks
[alexxy/gromacs.git] / admin / gitlab-ci / sample_restraint-regression.gitlab-ci.yml
1 # Test for API regression or unexpected breakage.
2
3 # Base job definition for sample_restraint tests against GROMACS 2020.
4 .sample_restraint:clang-8:gmx2020:
5   extends:
6     - .variables:default
7     - .use-clang8
8   stage: test
9   variables:
10     PLUGIN_TEST_XML: $CI_PROJECT_DIR/py-JUnitTestResults.xml
11     PLUGIN_MPI_TEST_XML: $CI_PROJECT_DIR/py-mpi-JUnitTestResults.xml
12     EXTRA_INSTALLS: "curl libbz2-dev libffi-dev liblzma-dev libncurses5-dev libncursesw5-dev libreadline-dev libsqlite3-dev libssl-dev llvm python-openssl tk-dev zlib1g-dev"
13   script:
14     - source $INSTALL_DIR/bin/GMXRC
15     - source $VENVPATH/bin/activate && INSTALL_DIR=$PWD/$INSTALL_DIR bash -x admin/ci-scripts/build-and-test-sample_restraint-2020.sh
16   artifacts:
17     reports:
18       junit:
19         - $PLUGIN_TEST_XML
20         - $PLUGIN_MPI_TEST_XML
21     when: always
22     expire_in: 1 week
23   needs:
24     - project: gromacs/gromacs
25       job: gromacs:clang-8:build
26       ref: release-2020
27       artifacts: true
28
29 sample_restraint:clang-8:gmx2020:3.5.9:
30   extends:
31     - .sample_restraint:clang-8:gmx2020
32   # Run only for changes affecting the python_packaging subdirectory of the release-2020 branch.
33   rules:
34     - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
35       when: never
36     # Allow explicit trigger through web interface.
37     - if: '$GMX_GMXAPI_0_2'
38       when: always
39     - if: '$GROMACS_RELEASE'
40       when: never
41     # Run this job only for release-2020 branch and merge-requests targeting it.
42     - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "release-2020" && $CI_COMMIT_BRANCH != "release-2020"'
43       when: never
44     # GROMACS 2020 API is final, so only test on schedules or when merge requests update the python_packaging sources.
45     - changes:
46         - python_packaging
47       when: always
48   variables:
49     VENVPATH: "/root/venv/py3.5"
50     PY_VER: "3.5.9"
51
52 sample_restraint:clang-8:gmx2020:py-3.6.10:
53   extends:
54     - .sample_restraint:clang-8:gmx2020
55   # Run only for changes affecting the python_packaging subdirectory of the release-2020 branch.
56   rules:
57     - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
58       when: never
59     # Allow explicit trigger through web interface.
60     - if: '$GMX_GMXAPI_0_2'
61       when: always
62     - if: '$GROMACS_RELEASE'
63       when: never
64     # Run this job only for release-2020 branch and merge-requests targeting it.
65     - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "release-2020" && $CI_COMMIT_BRANCH != "release-2020"'
66       when: never
67     # GROMACS 2020 API is final, so only test on schedules or when merge requests update the python_packaging sources.
68     - changes:
69         - python_packaging
70       when: always
71   variables:
72     VENVPATH: "/root/venv/py3.6"
73     PY_VER: "3.6.10"
74
75 sample_restraint:clang-8:gmx2020:py-3.7.7:
76   extends:
77     - .sample_restraint:clang-8:gmx2020
78   # Run only for changes affecting the python_packaging subdirectory of the release-2020 branch.
79   rules:
80     - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
81       when: never
82     # Allow explicit trigger through web interface.
83     - if: '$GMX_GMXAPI_0_2'
84       when: always
85     - if: '$GROMACS_RELEASE'
86       when: never
87     # Run this job only for release-2020 branch and merge-requests targeting it.
88     - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "release-2020" && $CI_COMMIT_BRANCH != "release-2020"'
89       when: never
90     # GROMACS 2020 API is final, so only test on schedules or when merge requests update the python_packaging sources.
91     - changes:
92         - python_packaging
93       when: always
94   variables:
95     VENVPATH: "/root/venv/py3.7"
96     PY_VER: "3.7.7"
97
98 sample_restraint:clang-8:gmx2020:py-3.8.2:
99   extends:
100     - .sample_restraint:clang-8:gmx2020
101   # Run only for changes affecting the python_packaging subdirectory of the release-2020 branch.
102   rules:
103     - if: '$CI_PROJECT_NAMESPACE != "gromacs"'
104       when: never
105     # Allow explicit trigger through web interface.
106     - if: '$GMX_GMXAPI_0_2'
107       when: always
108     - if: '$GROMACS_RELEASE'
109       when: never
110     # Run this job only for release-2020 branch and merge-requests targeting it.
111     - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "release-2020" && $CI_COMMIT_BRANCH != "release-2020"'
112       when: never
113     # GROMACS 2020 API is final, so only test on schedules or when merge requests update the python_packaging sources.
114     - changes:
115       - python_packaging
116       when: always
117   variables:
118     VENVPATH: "/root/venv/py3.8"
119     PY_VER: "3.8.2"