-
Notifications
You must be signed in to change notification settings - Fork 243
55 lines (49 loc) · 1.38 KB
/
ui-e2e.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
name: Dev UI E2E tests
on:
pull_request:
branches:
- main
paths:
- 'ui/**'
- '.github/workflows/ui-e2e.yaml'
jobs:
cypress-run:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- name: Build odo
run: make bin
- name: Set odo in system path
run: |
mkdir -p "$HOME/.local/bin/"
mv ./odo "$HOME/.local/bin/odo"
chmod +x "$HOME/.local/bin/odo"
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Cypress run
uses: cypress-io/github-action@v6
env:
ODO_EXPERIMENTAL_MODE: "true"
ODO_TRACKING_CONSENT: "no"
with:
working-directory: ui
# Run odo against the UI itself
start: |
odo api-server --port 20000
npm start
wait-on: 'http://localhost:20000, http://localhost:4200'
wait-on-timeout: 180
# after the test run completes, store videos and any screenshots only upon a failure
- uses: actions/upload-artifact@v4
if: failure()
with:
name: cypress-artifacts
path: |
ui/cypress/screenshots/
ui/cypress/videos/
if-no-files-found: warn
retention-days: 7