-
Notifications
You must be signed in to change notification settings - Fork 19
44 lines (33 loc) · 1.05 KB
/
photon-os-installer.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
name: photon-os-installer CI
on: [pull_request, push, workflow_dispatch]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Build Docker image
run: |
POI_IMAGE_NAME=photon/installer:${{ github.sha }}
cd docker
docker build -t $POI_IMAGE_NAME --build-context poi-helper=$(realpath $(pwd)/..) .
docker system prune -f
test:
runs-on: ubuntu-latest
needs: build # This ensures the test job runs after the build job
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.x # Specify the Python version you need
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt # Ensure this file lists the necessary dependencies
- name: install pytest
run: pip install pytest
- name: Run Pytest
run: |
pytest -x tests/poi-container-test.py