This repository was archived by the owner on Sep 9, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 36
60 lines (51 loc) · 1.39 KB
/
ci.yml
File metadata and controls
60 lines (51 loc) · 1.39 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
49
50
51
52
53
54
55
56
57
58
59
60
name: ci-build
on: [push]
jobs:
# Test and build client library
test-client:
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install requests pytest build
- name: Install client package in development mode
run: |
cd client
pip install -e .
- name: Run client tests
run: |
cd client
python -m pytest tests/ -v
- name: Build client package
run: |
cd client
python -m build
# Build and test webapp container
build-and-push:
runs-on: ubuntu-latest
needs: test-client
steps:
- name: Checkout main
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: Build
env:
IMAGE_TAG: ${{ env.RELEASE_VERSION }}
run: |
docker build -t cogstacksystems/medcat-trainer:dev-latest webapp/.
- name: Run Django Tests
env:
IMAGE_TAG: ${{ env.RELEASE_VERSION }}
run: |
# run tests
docker run --rm cogstacksystems/medcat-trainer:dev-latest python manage.py test