Skip to content

Commit

Permalink
Update pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
schmoelder committed Dec 4, 2024
1 parent 79ea7a2 commit 119b7e1
Showing 1 changed file with 39 additions and 39 deletions.
78 changes: 39 additions & 39 deletions .github/workflows/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,48 +19,48 @@ jobs:
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4

- name: Get Date
id: get-date
run: echo "today=$(/bin/date -u '+%Y%m%d')" >> $GITHUB_OUTPUT
shell: bash
- name: Get Date
id: get-date
run: echo "today=$(/bin/date -u '+%Y%m%d')" >> $GITHUB_OUTPUT
shell: bash

- name: Setup Conda Environment
uses: conda-incubator/setup-miniconda@v3
with:
miniforge-variant: Mambaforge
use-mamba: true
activate-environment: cadet-python
channels: conda-forge,
- name: Setup Conda Environment
uses: conda-incubator/setup-miniconda@v3
with:
miniforge-version: latest
use-mamba: true
activate-environment: cadet-python
channels: conda-forge,

- name: Cache conda
uses: actions/cache@v3
env:
# Increase this value to reset cache if environment.yml has not changed
CACHE_NUMBER: 0
with:
path: ${{ env.CONDA }}/envs
key: python_${{ matrix.python-version }}-${{ steps.get-date.outputs.today }}-${{ env.CACHE_NUMBER }}
- name: Cache conda
uses: actions/cache@v3
env:
# Increase this value to reset cache if environment.yml has not changed
CACHE_NUMBER: 0
with:
path: ${{ env.CONDA }}/envs
key: python_${{ matrix.python-version }}-${{ steps.get-date.outputs.today }}-${{ env.CACHE_NUMBER }}

- name: Set up python env
run: |
mamba install python==${{ matrix.python-version }}
pip install .
- name: Install pypa/build
run: |
python -m pip install build --user
- name: Set up python env
run: |
mamba install python==${{ matrix.python-version }}
pip install .
- name: Install pypa/build
run: |
python -m pip install build --user
- name: Build binary wheel and source tarball
run: |
python -m build --sdist --wheel --outdir dist/ .
- name: Build binary wheel and source tarball
run: |
python -m build --sdist --wheel --outdir dist/ .
- name: Test Wheel install and import
run: |
python -c "import cadet; print(cadet.__version__)"
cd ..
- name: Test with pytest
run: |
pip install .[testing]
mamba install cadet -c conda-forge
pytest tests --rootdir=tests -m "not slow and not local"
- name: Test Wheel install and import
run: |
python -c "import cadet; print(cadet.__version__)"
cd ..
- name: Test with pytest
run: |
pip install .[testing]
mamba install cadet>5.0.2 -c conda-forge
pytest tests --rootdir=tests -m "not slow and not local"

0 comments on commit 119b7e1

Please sign in to comment.