-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (56 loc) · 1.45 KB
/
test.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
---
name: Test
on:
pull_request:
branches:
- master
push:
branches:
- master
- dev
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Run tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Set up Node.js
uses: actions/[email protected]
with:
node-version: 20.x
registry-url: https://registry.npmjs.org
- name: Set up Python
uses: actions/[email protected]
with:
python-version: ${{ matrix.python-version }}
- name: Use npm cache
uses: actions/[email protected]
with:
path: ~/.npm
key: npm
- name: Use pip cache
uses: actions/[email protected]
with:
path: ~/.cache/pip
key: pip-${{ matrix.python-version }}
- name: Use tox cache
uses: actions/[email protected]
with:
path: .tox
key: tox-${{ matrix.python-version }}-${{ hashFiles('requirements.txt', 'requirements-dev.txt') }}
- name: Install test requirements
run: |
make install-test-deps
sudo npm install -g prettier
- name: Run tests
run: make test
- name: Run codecov
uses: codecov/[email protected]