Add GitHub Actions workflows for publishing to Test PyPI and PyPI #586
Workflow file for this run
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: ci | |
on: push | |
jobs: | |
build: | |
runs-on: ${{ matrix.platform }} | |
strategy: | |
matrix: | |
platform: [ubuntu-latest, macos-latest] | |
python-version: ["3.9", "3.10", "3.11"] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: snok/install-poetry@v1 | |
with: | |
version: 1.3.2 | |
virtualenvs-create: true | |
virtualenvs-in-project: true | |
- run: poetry install --no-interaction --no-root | |
- uses: trunk-io/trunk-action@v1 | |
with: | |
check-mode: all | |
- name: Test | |
run: | | |
poetry run pytest --cov=./ --cov-report=xml -v | |
- name: Run codacy-coverage-reporter | |
uses: codacy/codacy-coverage-reporter-action@v1 | |
with: | |
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} | |
coverage-reports: coverage.xml | |
# - uses: codecov/codecov-action@v3 | |
# with: | |
# fail_ci_if_error: false | |
# token: ${{ secrets.CODECOV_TOKEN }} | |
# files: ./coverage.xml |