-
Notifications
You must be signed in to change notification settings - Fork 31
33 lines (31 loc) · 1 KB
/
unit_tests.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
name: Run unit tests
on:
pull_request:
branches: [main]
types: [opened, synchronize]
permissions: {}
jobs:
model-signing-unit-tests:
name: Run unit tests for signing
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
with:
python-version: 3.11
cache: pip
cache-dependency-path: |
model_signing/install/requirements.txt
model_signing/install/requirements.test.txt
- name: Install dependencies
run: |
set -euo pipefail
python -m venv venv
source venv/bin/activate
python -m pip install --require-hashes -r model_signing/install/requirements.txt
python -m pip install --require-hashes -r model_signing/install/requirements.test.txt
- name: Run unit tests
run: |
set -euo pipefail
source venv/bin/activate
pytest -v --full-trace .