Use [email protected] for FEniCS CI #27
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Firedrake | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
container: | |
image: docker://firedrakeproject/firedrake-vanilla:latest | |
steps: | |
# This Docker file changes sets USER to firedrake instead of using the default user, so we need to update file permissions for this image to work on GH Actions. | |
# See https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners#docker-container-filesystem | |
# (copied from https://help.github.com/en/actions/migrating-to-github-actions/migrating-from-circleci-to-github-actions) | |
- name: Setup file system permissions | |
run: sudo chmod -R 777 $GITHUB_WORKSPACE /github /__w/_temp | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 1 | |
- name: Python info | |
shell: bash -l {0} | |
run: | | |
source /home/firedrake/firedrake/bin/activate | |
which python | |
python -c "import sys; print('\n'.join(sys.path))" | |
python -c "from firedrake import *" | |
- name: Install dependencies | |
shell: bash -l {0} | |
run: | | |
source /home/firedrake/firedrake/bin/activate | |
python -m pip install --upgrade pip | |
python -m pip install pytest | |
python -m pip install pytest-cov | |
python -m pip install pytest-check | |
python -m pip install coveralls | |
python -m pip install fdm | |
python -m pip install git+https://github.com/dolfin-adjoint/pyadjoint.git@master | |
python -m pip install git+https://github.com/IvanYashchuk/fecr@master | |
python -m pip install --upgrade jax jaxlib | |
- name: Install current package | |
shell: bash -l {0} | |
run: | | |
source /home/firedrake/firedrake/bin/activate | |
python -m pip install -e . | |
- name: Test with pytest | |
shell: bash -l {0} | |
run: | | |
source /home/firedrake/firedrake/bin/activate | |
python -c "import sys; print('\n'.join(sys.path))" | |
python -m pytest --cov=jaxfenics_adjoint --cov-config=tests/.coveragerc tests/firedrake -vvv | |
- name: Send coveralls | |
shell: bash -l {0} | |
env: | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
run: | | |
source /home/firedrake/firedrake/bin/activate | |
coveralls |