Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run pytest using local conda installation #265

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 11 additions & 19 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,33 +15,25 @@ jobs:

steps:
- uses: actions/checkout@v3
with:
# Fetch all history for all tags and branches (tag information is
# required when building the conda package)
fetch-depth: 0
- uses: conda-incubator/setup-miniconda@v2
with:
python-version: '3.9'
auto-activate-base: false
activate-environment: benchcab-dev
environment-file: .conda/benchcab-dev.yaml
- name: Build and install conda package
run: |
conda install conda-build
conda build -c conda-forge -c accessnri -c coecms .
conda install --no-channel-priority -c $CONDA_PREFIX/conda-bld -c conda-forge -c accessnri -c coecms benchcab
conda uninstall conda-build
- name: Test with pytest
run: |
conda install pytest-cov
pytest --cov=./ --cov-report=xml
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml

build_conda_package:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: conda-incubator/setup-miniconda@v2
with:
python-version: '3.9'
- name: Test conda build
run: |
conda install conda-build
conda build -c conda-forge -c accessnri -c coecms .
Loading