-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (61 loc) · 1.98 KB
/
unittest.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Playbase unittest
on:
pull_request:
workflow_dispatch:
env:
DOCKER_TAG: bigomics/omicsplayground:latest
jobs:
unittest:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
# -
# name: Setup upterm session
# uses: lhotari/action-upterm@v1
# with:
# ## limits ssh access and adds the ssh public key for the user which triggered the workflow
# limit-access-to-actor: true
# ## limits ssh access and adds the ssh public keys of the listed GitHub users
# limit-access-to-users: mauromiguelm
# wait-timeout-minutes: 120
-
name: Build OPG docker
id: build-opg-docker
run: |
docker build --build-arg DOCKER_TAG=$DOCKER_TAG -t $DOCKER_TAG -f ./.github/workflows/unittest/Dockerfile .
# -
# name: Setup upterm session
# uses: lhotari/action-upterm@v1
# with:
# ## limits ssh access and adds the ssh public key for the user which triggered the workflow
# limit-access-to-actor: true
# ## limits ssh access and adds the ssh public keys of the listed GitHub users
# limit-access-to-users: mauromiguelm
# wait-timeout-minutes: 120
-
name: Unittest docker
id: test-snapshot
run: |
docker run --name run_tests $DOCKER_TAG
docker cp run_tests:/test_result.txt .
-
name: Check workflow result
id: check-workflow-result
run: |
if [[ "${{ steps.test-snapshot.outputs.workflow_result }}" == "false" ]]; then
echo "Workflow failed."
exit 1
fi
-
name: Upload error log
if: always()
uses: actions/upload-artifact@v3
with:
name: test-error-log
path: ./test_result.txt
if-no-files-found: ignore