Skip to content

Commit

Permalink
Add downstream CI on Gitlab, refactor to rely on ci-support
Browse files Browse the repository at this point in the history
  • Loading branch information
inducer committed Apr 4, 2022
1 parent 90416c9 commit b51ef02
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 23 deletions.
27 changes: 4 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -169,34 +169,15 @@ jobs:
env:
DOWNSTREAM_PROJECT: ${{ matrix.downstream_project }}
run: |
# {{{ configure pyopencl so it finds its headers
curl -L -O https://tiker.net/ci-support-v0
. ./ci-support-v0
TEST_ENV_ROOT="$(pwd)/$DOWNSTREAM_PROJECT/.miniforge3/envs/testing"
./configure.py --cl-inc-dir="$TEST_ENV_ROOT/include" --cl-lib-dir="$TEST_ENV_ROOT/lib"
git add -f siteconf.py
git config --global user.email "inform@tiker.net"
git config --global user.name "Github CI runner"
git commit -a -m "Fake commit to add aksetup.py"
# }}}
git clone "https://github.com/inducer/$DOWNSTREAM_PROJECT.git"
cd "$DOWNSTREAM_PROJECT"
echo "*** $DOWNSTREAM_PROJECT version: $(git rev-parse --short HEAD)"
sed -i "/egg=pyopencl/ c git+file://$(readlink -f ..)#egg=pyopencl" requirements.txt
export CONDA_ENVIRONMENT=.test-conda-env-py3.yml
sed -i 's/pyopencl/ocl-icd/' "$CONDA_ENVIRONMENT"
# Avoid slow or complicated tests in downstream projects
export PYTEST_ADDOPTS="-k 'not (slowtest or octave or mpi)'"
curl -L -O https://tiker.net/ci-support-v0
. ./ci-support-v0
prepare_downstream_build "$DOWNSTREAM_PROJECT"
sed -i 's/pyopencl/ocl-icd/' .test-conda-env-py3.yml
build_py_project_in_conda_env
test_py_project
Expand Down
22 changes: 22 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -256,3 +256,25 @@ Flake8:
- python3
except:
- tags

Downstream:
parallel:
matrix:
- DOWNSTREAM_PROJECT: [loopy, boxtree, meshmode]
tags:
- large-node
- "docker-runner"
script: |
curl -L -O https://tiker.net/ci-support-v0
. ./ci-support-v0
TEST_ENV_ROOT="$(pwd)/$DOWNSTREAM_PROJECT/.miniforge3/envs/testing"
./configure.py --cl-inc-dir="$TEST_ENV_ROOT/include" --cl-lib-dir="$TEST_ENV_ROOT/lib"
git add -f siteconf.py
prepare_downstream_build "$DOWNSTREAM_PROJECT"
sed -i 's/pyopencl/ocl-icd/' .test-conda-env-py3.yml
build_py_project_in_conda_env
test_py_project
# vim: sw=2

0 comments on commit b51ef02

Please sign in to comment.