-
Notifications
You must be signed in to change notification settings - Fork 114
59 lines (51 loc) · 1.31 KB
/
api-e2e.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
name: API E2E tests
on:
pull_request:
types:
- opened
- edited
- reopened
- synchronize
jobs:
runE2ETests:
name: Run E2E tests
timeout-minutes: 10
runs-on: ubuntu-latest
permissions:
contents: read
issues: read
checks: write
pull-requests: write
defaults:
run:
working-directory: ./packages/api
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Start docker containers
run: |
docker-compose -f "docker-compose.e2e.yaml" up -d --build
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
cache: 'npm'
- name: Install dependencies
run: |
npm ci --ignore-scripts
- name: Run e2e tests
run: |
npm run test:e2e
- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action/composite@v2
if: always()
with:
files: "packages/api/e2e-junit.xml"
check_run_annotations: all tests, skipped tests
report_individual_runs: "true"
check_name: API E2E Test Results
- name: Stop containers
if: always()
run: docker-compose -f "docker-compose.e2e.yaml" down