-
Notifications
You must be signed in to change notification settings - Fork 68
48 lines (41 loc) · 1.28 KB
/
pytest.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
name: tests
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
fail-fast: false
env:
IS_GITHUB_RUNNER: "true"
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: Install dependencies
run: |
pip install --upgrade pip
pip install poetry
poetry export --dev --without-hashes --output requirements.txt
pip install -r requirements.txt
sudo apt install progress -y
- name: Run tests
run: pytest
- name: Run Mypy
run: mypy recoverpy --strict
automerge-dependabot:
runs-on: ubuntu-latest
needs: test
if: github.actor == 'dependabot[bot]' && github.event.pull_request.user.login == 'dependabot[bot]'
steps:
- name: Enable auto-merge for Dependabot PRs
run: gh pr merge --auto --merge "$PR_URL"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GH_TOKEN: ${{ secrets.DEPENDABOT_TOKEN }}
GITHUB_TOKEN: ${{ secrets.DEPENDABOT_TOKEN }}