From 4ad3320608f10826e078673e36425e8ce2f4496e Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner Date: Thu, 24 Mar 2022 15:32:50 -0500 Subject: [PATCH] Downstream CI: use ci-support, add Gitlab --- .ci/install-downstream.sh | 31 ------------------------------- .github/workflows/ci.yml | 21 ++------------------- .gitlab-ci.yml | 14 ++++++++++++++ 3 files changed, 16 insertions(+), 50 deletions(-) delete mode 100755 .ci/install-downstream.sh diff --git a/.ci/install-downstream.sh b/.ci/install-downstream.sh deleted file mode 100755 index f9b0e36b..00000000 --- a/.ci/install-downstream.sh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash - -# Installs the downstream project specified in $DOWNSTREAM_PROJECT - -set -o errexit - -if [[ "$DOWNSTREAM_PROJECT" = "mirgecom" ]]; then - git clone "https://github.com/illinois-ceesd/$DOWNSTREAM_PROJECT.git" -else - git clone "https://github.com/inducer/$DOWNSTREAM_PROJECT.git" -fi - -cd "$DOWNSTREAM_PROJECT" -echo "*** $DOWNSTREAM_PROJECT version: $(git rev-parse --short HEAD)" - -transfer_requirements_git_urls ../requirements.txt ./requirements.txt -edit_requirements_txt_for_downstream_in_subdir - -export CONDA_ENVIRONMENT=.test-conda-env-py3.yml - -# Avoid slow or complicated tests in downstream projects -export PYTEST_ADDOPTS="-k 'not (slowtest or octave or mpi)'" - -if [[ "$DOWNSTREAM_PROJECT" = "mirgecom" ]]; then - # can't turn off MPI in mirgecom - export CONDA_ENVIRONMENT=conda-env.yml - export CISUPPORT_PARALLEL_PYTEST=no - echo "- mpi4py" >> "$CONDA_ENVIRONMENT" -else - sed -i "/mpi4py/ d" requirements.txt -fi diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 21239a68..5bdb399a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -127,7 +127,7 @@ jobs: downstream_tests: strategy: matrix: - downstream_project: [grudge, pytential, mirgecom] + downstream_project: [grudge, pytential, mirgecom, mirgecom_examples] name: Tests for downstream project ${{ matrix.downstream_project }} runs-on: ubuntu-latest steps: @@ -138,23 +138,6 @@ jobs: run: | curl -L -O https://tiker.net/ci-support-v0 . ./ci-support-v0 - source .ci/install-downstream.sh - build_py_project_in_conda_env - test_py_project - - mirgecom_examples: - runs-on: ubuntu-latest - name: Examples for downstream project mirgecom - steps: - - uses: actions/checkout@v2 - - name: "Main Script" - env: - DOWNSTREAM_PROJECT: mirgecom - run: | - curl -L -O https://tiker.net/ci-support-v0 - . ./ci-support-v0 - source .ci/install-downstream.sh - build_py_project_in_conda_env - examples/run_examples.sh ./examples + test_downstream "$DOWNSTREAM_PROJECT" # vim: sw=4 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2b8ef1cb..67ec280c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -111,3 +111,17 @@ Pylint: - python3 except: - tags + +Downstream: + parallel: + matrix: + - DOWNSTREAM_PROJECT: [grudge, pytential, mirgecom, mirgecom_examples] + tags: + - large-node + - "docker-runner" + script: | + curl -L -O https://tiker.net/ci-support-v0 + . ./ci-support-v0 + test_downstream "$DOWNSTREAM_PROJECT" + +# vim: sw=2 -- GitLab