-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (42 loc) · 1.09 KB
/
python.yaml
File metadata and controls
46 lines (42 loc) · 1.09 KB
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
name: Python tests
on:
pull_request:
workflow_dispatch:
env:
PY_VERSION: '3.10'
IMAGE_NAME: "qatcomputer"
jobs:
style:
runs-on: ubuntu-22.04
steps:
- uses: actions/setup-python@v5
with:
python-version: ${{ env.PY_VERSION }}
- uses: actions/checkout@v4
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: Run lint check
run: tox -elint
- name: Run black check
run: tox -eblack
end2end:
runs-on: ubuntu-22.04
timeout-minutes: 5
steps:
- uses: actions/setup-python@v5
with:
python-version: ${{ env.PY_VERSION }}
- uses: actions/checkout@v4
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: Build image
run: |
docker build . --build-arg FULL=false --file docker/Dockerfile --tag ${{ env.IMAGE_NAME }}:latest
- name: Test using tox environment
run: |
pver=${{ env.PY_VERSION }}
tox -epy${pver/./}