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

Update actions #34

Merged
merged 3 commits into from
Oct 28, 2024
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
39 changes: 28 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@ jobs:
run: pip install -e ".[dev]"

- name: Run tests
run: python -m pytest -v --cov src tests/unit
run: python -m pytest -v --cov-report xml:coverage.xml --cov src tests/unit

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}-${{ matrix.python-version }}-unit-tests-coverage
path: ./coverage.xml

integration-tests:
runs-on: ${{ matrix.os }}
Expand Down Expand Up @@ -80,20 +80,20 @@ jobs:
run: pip install -e ".[dev]"

- name: Run tests
run: python -m pytest -v --cov src tests/integration
run: python -m pytest -v --cov-report xml:coverage.xml --cov src tests/integration

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}-integration-tests-coverage
path: ./coverage.xml

static-tests:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: "pip"
Expand All @@ -109,3 +109,20 @@ jobs:

- name: Run ruff linter
run: python -m ruff check .

upload-codecov-reports:
needs:
- unit-tests
- integration-tests

runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download artifacts
uses: actions/download-artifact@v4
- name: Upload to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Loading