-
Notifications
You must be signed in to change notification settings - Fork 13
48 lines (43 loc) · 1.36 KB
/
unit-test.yml
File metadata and controls
48 lines (43 loc) · 1.36 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
47
48
name: Unit Tests
on: [pull_request]
jobs:
test:
runs-on: ubuntu-latest
continue-on-error: true
timeout-minutes: 15
strategy:
# Don't cancel jobs if one fails
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Start databases
working-directory: ./sample-apps/databases
run: docker compose up --build -d
- name: Add local.aikido.io to /etc/hosts
run: |
sudo echo "127.0.0.1 local.aikido.io" | sudo tee -a /etc/hosts
- name: Build and start aikido mock server
run: |
cd end2end/server && docker build -t mock_core .
docker run --name mock_core -d -p 5050:5000 mock_core
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
make install
- name: Run tests with coverage
run: |
make cov
- name: Upload coverage report to Codecov
uses: codecov/codecov-action@b9fd7d16f6d7d1b5d2bec1a2887e65ceed900238 # v4
with:
fail_ci_if_error: true
files: ./coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true