2022-09-08 08:40:58 +02:00
|
|
|
---
|
2023-05-06 14:54:05 +02:00
|
|
|
name: PyKanidm tests
|
2022-06-20 12:16:55 +02:00
|
|
|
|
|
|
|
"on":
|
|
|
|
push:
|
2023-05-06 14:54:05 +02:00
|
|
|
branches:
|
|
|
|
- "master"
|
2022-06-20 12:16:55 +02:00
|
|
|
pull_request:
|
2022-11-13 23:57:05 +01:00
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
cancel-in-progress: true
|
2022-06-20 12:16:55 +02:00
|
|
|
jobs:
|
2023-05-06 14:54:05 +02:00
|
|
|
tests:
|
2022-06-20 12:16:55 +02:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2022-07-05 09:33:53 +02:00
|
|
|
- uses: actions/checkout@v3
|
2022-06-20 12:16:55 +02:00
|
|
|
with:
|
|
|
|
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
|
2022-11-13 23:57:05 +01:00
|
|
|
- name: Install poetry
|
|
|
|
run: pipx install poetry
|
2022-09-29 02:08:15 +02:00
|
|
|
- name: Set up Python 3.10
|
2022-07-05 09:40:37 +02:00
|
|
|
uses: actions/setup-python@v4
|
2022-06-20 12:16:55 +02:00
|
|
|
with:
|
2022-09-29 02:08:15 +02:00
|
|
|
python-version: '3.10'
|
2022-11-13 23:57:05 +01:00
|
|
|
cache: 'poetry'
|
2022-06-20 12:16:55 +02:00
|
|
|
- name: Running mypy
|
|
|
|
run: |
|
|
|
|
cd pykanidm
|
|
|
|
python --version
|
|
|
|
poetry install
|
|
|
|
poetry run mypy --strict kanidm tests
|
2023-05-06 14:54:05 +02:00
|
|
|
- name: Running Linting
|
|
|
|
run: |
|
|
|
|
cd pykanidm
|
|
|
|
poetry install
|
|
|
|
poetry run ruff kanidm tests
|
|
|
|
- name: Running pytest
|
|
|
|
run: |
|
|
|
|
cd pykanidm
|
|
|
|
poetry install
|
|
|
|
poetry run pytest -v
|