Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
KonstantinChri committed Sep 4, 2024
1 parent 66febed commit ad5868b
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,47 +3,49 @@ name: Tests
on:
push:
branches:
- main
- '**'
tags:
- v*
pull_request:

jobs:
tests:
name: pytests (${{ matrix.os }}, Mambaforge)
name: pytests (${{ matrix.os }} - ${{ matrix.python-version }}, Mambaforge)
runs-on: ${{ matrix.os }}-latest
defaults:
run:
shell: bash -l {0}
strategy:
matrix:
os: ["ubuntu", "windows"]
python-version: [ '3.8', '3.9', '3.10', '3.11' ]
os: ["ubuntu", "macos"]
python-version: [ '3.8','3.9', '3.10', '3.11' ]
steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
environment-file: environment.yml
python-version: ${{ matrix.python-version }}
miniforge-version: latest
miniforge-variant: Mambaforge
- name: Install Poetry
run: |
curl -sSL https://install.python-poetry.org | python -
- name: Add Poetry to PATH
run: |
echo "$HOME/.poetry/bin:$PATH" >> $GITHUB_ENV
- name: Run tests and build wheels

- name: Run tests
run: |
conda activate test
pytest -vs --log-cli-level=debug
- name: Build wheels
run: |
conda activate test
mamba install -c conda-forge poetry
poetry build
- name: Upload wheels
if: matrix.python-version == '3.10' && matrix.os == 'ubuntu'
uses: actions/upload-artifact@v2
with:
name: wheels
path: dist

release:
name: Release
runs-on: ubuntu-latest
Expand All @@ -64,4 +66,4 @@ jobs:
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
pip install --upgrade twine
twine upload --skip-existing *
twine upload --skip-existing *.tar.gz

0 comments on commit ad5868b

Please sign in to comment.