Skip to content

Commit e645930

Browse files
digitronikNikhil
authored andcommitted
improve wrokflows
1 parent 24680e4 commit e645930

2 files changed

Lines changed: 23 additions & 11 deletions

File tree

.github/workflows/lint.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
11
name: Lint
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
type: [ "opened", "reopened", "synchronize" ]
49

510
env:
611
FORCE_COLOR: 1
712

813
jobs:
914
build:
15+
name: pre-commit
1016
runs-on: ubuntu-latest
1117

1218
steps:
@@ -26,7 +32,7 @@ jobs:
2632
- name: Set up Python
2733
uses: actions/setup-python@v2
2834
with:
29-
python-version: 3.8
35+
python-version: '3.x'
3036

3137
- name: Install dependencies
3238
run: |

.github/workflows/test.yml

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
11
name: Test
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
type: [ "opened", "reopened", "synchronize" ]
49

510
env:
611
FORCE_COLOR: 1
712

813
jobs:
914
build:
15+
name: py-${{ matrix.python-version }}:pytest-${{ matrix.pytest-version }}
1016
runs-on: ubuntu-latest
1117
strategy:
1218
fail-fast: false
@@ -19,13 +25,13 @@ jobs:
1925
"pypy3",
2026
]
2127
pytest-version: [
22-
"5.0.1",
23-
"5.1.3",
24-
"5.2.4",
25-
"5.3.5",
26-
"5.4.3",
27-
"6.0.2",
28-
"6.1.1",
28+
"5.0",
29+
"5.1",
30+
"5.2",
31+
"5.3",
32+
"5.4",
33+
"6.0",
34+
"6.1",
2935
]
3036
steps:
3137
- uses: actions/checkout@v2
@@ -52,7 +58,7 @@ jobs:
5258
- name: Install dependencies
5359
run: |
5460
python -m pip install -U pip
55-
python -m pip install pytest==${{ matrix.pytest-version }}
61+
python -m pip install pytest~=${{ matrix.pytest-version }}
5662
python -m pip install -e .
5763
5864
- name: Tests

0 commit comments

Comments
 (0)