forked from haddocking/arctic3d
-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (38 loc) · 1.38 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
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
- name: Check types
run: poetry run mypy src/ --ignore-missing-imports --explicit-package-bases --disallow-incomplete-defs # --check-untyped-defs
- name: Run sanity check on the API endpoints
run: poetry run pytest -m sanity -vvv
- name: Run unit tests
run: poetry run pytest -m "not (sanity or integration)" --cov=./ --cov-report=xml -v
- name: Run integration tests
run: poetry run pytest -m integration
- 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