-
Notifications
You must be signed in to change notification settings - Fork 3
71 lines (63 loc) · 1.75 KB
/
testing_master.yaml
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
---
name: Testing Master
# yamllint disable-line rule:truthy
on:
workflow_dispatch:
push:
branches:
- "main"
paths:
- '.github/workflows/testing_master.yaml'
- 'master/**'
- 'test/unit/master/**'
- 'test/unit/storage/**'
- 'pyproject.toml'
- 'poetry.lock'
pull_request:
branches:
- "main"
paths:
- '.github/workflows/testing_master.yaml'
- 'master/**'
- 'test/unit/master/**'
- 'test/unit/storage/**'
- 'pyproject.toml'
- 'poetry.lock'
concurrency:
# yamllint disable-line rule:line-length
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
jobs:
testing:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
id: setup-python
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: 1.2.2
installer-parallel: true
- name: Load cached venv
id: cached-poetry-dependencies
uses: actions/cache@v3
with:
path: .venv
key: "
venv\
-${{ runner.os }}\
-${{ steps.setup-python.outputs.python-version }}\
-${{ hashFiles('**/poetry.lock') }}"
- name: Install dependencies
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
run: |
poetry install --no-interaction --with 'master,dev'
- name: "Unit tests"
run: poetry run scripts/run-test-unit