-
Notifications
You must be signed in to change notification settings - Fork 163
59 lines (50 loc) · 1.76 KB
/
linux-build-and-test.yaml
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
name: Build-Test-Linux
on:
workflow_dispatch:
jobs:
build-test-linux:
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- name: Build
run: |
docker build -t "bincat:ci-test" . -f "docker/Dockerfile.runtests"
- name: Run tests
run: |
mkdir -p out
docker run --rm -v "$(pwd)"/out:/out -w /install/bincat/test "bincat:ci-test" bash -x -c 'python3 -m pytest --coverage smoke -k "not repne" --junitxml=/install/bincat/test-results/pytest_report.xml || true; cp /install/bincat/test-results/pytest_report.xml /out/'
- name: Upload Test Results
uses: actions/upload-artifact@v4
with:
name: Unit Test Results
path: out/pytest_report.xml
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
files: out/pytest_report.xml
- name: Build BinCAT for Linux installer
#if: ${{ github.event.type == 'PushEvent' && github.event.ref == 'refs/heads/master' }}
run: |
mkdir -p out
docker run -v "$(pwd)"/out:/out -w /install/bincat "bincat:ci-test" bash -x -c 'make lindist && cp -R bincat-linux-* /out; find /out'
echo "-- find --"
find out
- name: Publish BinCAT for Linux installer
uses: actions/upload-artifact@v4
with:
name: bincat-installer
path: out/bincat-linux-*.tar.xz
event_file:
name: "Event File"
runs-on: ubuntu-latest
steps:
- name: Upload
uses: actions/upload-artifact@v4
with:
name: Event File
path: ${{ github.event_path }}