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: FEniCS | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 1 | |
- name: Setup Miniconda | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
auto-update-conda: true | |
python-version: 3.8 | |
mamba-version: "*" | |
channels: conda-forge,defaults | |
channel-priority: true | |
- name: Conda info | |
shell: bash -l {0} | |
run: | | |
conda info | |
which python | |
- name: Mamba install FEniCS | |
shell: bash -l {0} | |
run: | | |
conda config --set always_yes yes | |
conda config --add channels conda-forge | |
mamba create -n fenicsproject -c conda-forge fenics | |
conda activate fenicsproject | |
which python | |
python -c "from dolfin import *" | |
- name: Install dependencies | |
shell: bash -l {0} | |
run: | | |
conda activate fenicsproject | |
python -m pip install --upgrade pip | |
python -m pip install git+https://github.com/dolfin-adjoint/[email protected] | |
python -m pip install git+https://github.com/IvanYashchuk/fecr@master | |
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 --upgrade jax jaxlib | |
- name: Install JAX-FEniCS | |
shell: bash -l {0} | |
run: | | |
conda activate fenicsproject | |
python -m pip install . | |
- name: Print path | |
shell: bash -l {0} | |
run: python -c "import sys; print('\n'.join(sys.path))" | |
- name: Test with pytest | |
shell: bash -l {0} | |
run: | | |
conda activate fenicsproject | |
python -c "import sys; print('\n'.join(sys.path))" | |
python -m pytest --cov=jaxfenics_adjoint --cov-config=tests/.coveragerc tests/fenics -vvv | |
- name: Send coveralls | |
shell: bash -l {0} | |
env: | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
run: | | |
conda activate fenicsproject | |
coveralls |