-
Notifications
You must be signed in to change notification settings - Fork 44
72 lines (61 loc) · 2.23 KB
/
e2e_tests.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
64
65
66
67
68
69
70
71
72
name: E2E Tests
on:
pull_request:
branches-ignore:
- 'weblate-**'
workflow_dispatch:
inputs:
distinct_id:
description: 'for the return-dispatch action'
required: false
control-api:
description: 'custom control-api version'
data-api:
description: 'custom data-api version'
us:
description: 'custom us version'
env:
CONTROL_API_VERSION: ${{github.event.inputs.control-api}}
DATA_API_VERSION: ${{github.event.inputs.data-api}}
US_VERSION: ${{github.event.inputs.us}}
concurrency:
group: ${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
run-e2e:
name: Install Datalens and Run E2E Tests
runs-on: ubuntu-latest
steps:
- name: echo distinct ID ${{ github.event.inputs.distinct_id }}
run: echo ${{ github.event.inputs.distinct_id }}
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 20
cache: 'npm'
cache-dependency-path: ./package-lock.json
- name: Check Docker Compose Config
working-directory: ./tests
run: docker compose -f ./docker-compose.e2e.yml config
- name: Run Docker Compose and Install dependencies for Datalens-UI
working-directory: ./tests
run: |
sudo rm /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update
docker compose -f ./docker-compose.e2e.yml up -d & cd .. && npm ci && npm run test:install:chromium & wait
- name: Run Test
run: E2E_DOMAIN="http://localhost:8080" E2E_RETRY_TIMES=1 NO_AUTH=true npm run test:e2e:opensource
- name: Run Docker Shutdown
working-directory: ./tests
run: docker compose -f ./docker-compose.e2e.yml down
- name: Save report link and pr
if: always()
run: |
echo "reports/${{ github.head_ref || github.ref_name }}/${{ github.run_id }}/${{ github.run_attempt }}" > ./tests/artifacts/report-link
echo "${{ github.event.pull_request.number }}" > ./tests/artifacts/report-pr
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: ./tests/artifacts/
retention-days: 30