Skip to content

Commit

Permalink
Use nox sessions in GH workflow for CI
Browse files Browse the repository at this point in the history
  • Loading branch information
tomuben committed Oct 2, 2024
1 parent 4a53464 commit efd67ab
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check_version.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- name: SCM Checkout
uses: actions/checkout@v3
- name: Setup Python & Poetry Environment
uses: exasol/python-toolbox/.github/actions/python-environment@0.12.0
uses: exasol/python-toolbox/.github/actions/python-environment@0.15.0
with:
python-version: "3.10"
poetry-version: '1.8.2'
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Checks

on:
pull_request:

jobs:

lint-job:
name: Linting and Type checks (Python-${{ matrix.python-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11", "3.12"]

steps:
- name: SCM Checkout
uses: actions/checkout@v4

- name: Setup Python & Poetry Environment
uses: exasol/python-toolbox/.github/actions/[email protected]
with:
python-version: ${{ matrix.python-version }}

- name: Run Unit Tests
run: poetry run nox -s unit-tests

- name: Run Lint
run: poetry run nox -s lint

- name: Run type-check
run: poetry run nox -s type-check

- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: ".lint-python-${{ matrix.python-version }}.txt"
path: .lint.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Run Unit Tests
name: Run Integration Tests

on:
push:
Expand All @@ -14,9 +14,9 @@ jobs:
- name: SCM Checkout
uses: actions/checkout@v4
- name: Setup Python & Poetry Environment
uses: exasol/python-toolbox/.github/actions/python-environment@0.12.0
uses: exasol/python-toolbox/.github/actions/python-environment@0.15.0
with:
python-version: "3.10"
poetry-version: '1.8.2'
- name: Run pytest
run: poetry run pytest
run: nox -s integration-tests
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
uses: actions/checkout@v3

- name: Setup Python & Poetry Environment
uses: exasol/python-toolbox/.github/actions/python-environment@0.12.0
uses: exasol/python-toolbox/.github/actions/python-environment@0.15.0
with:
python-version: "3.10"
poetry-version: '1.8.2'
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit efd67ab

Please sign in to comment.