-
Notifications
You must be signed in to change notification settings - Fork 2
124 lines (107 loc) · 3.17 KB
/
ci-nuxtjs.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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
name: Build - Nuxt App
on:
pull_request:
types: [opened, synchronize, reopened, "ready_for_review"]
paths:
- '.github/workflows/**'
- 'nuxt-app/**'
- 'webdriver-helpers/**'
- 'wdio.conf.js'
- 'test/**'
- 'playwright-helpers/**'
push:
branches:
- main
concurrency:
group: CI-Nuxt-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
jobs:
build-nuxt-app-windows-node18:
name: Windows - Node 18
uses: ./.github/workflows/build.yml
with:
build-script: 'generate'
deploy: false
node-version: 18
os: 'windows-latest'
package-name: 'nuxt-app'
secrets: inherit
build-nuxt-app-windows-node20:
name: Windows - Node 20
uses: ./.github/workflows/build.yml
with:
build-script: 'generate'
deploy: false
node-version: 20
os: 'windows-latest'
package-name: 'nuxt-app'
secrets: inherit
build-nuxt-app-ubuntu-node18:
name: Ubuntu - Node 18
uses: ./.github/workflows/build.yml
with:
build-script: 'generate'
deploy: false
node-version: 18
os: 'ubuntu-latest'
package-name: 'nuxt-app'
secrets: inherit
build-deploy-nuxt-app-ubuntu-node20:
name: Ubuntu - Node 20
uses: ./.github/workflows/build.yml
with:
build-script: 'generate'
deploy: true
node-version: 20
os: 'ubuntu-latest'
amplify-app-id: 'd36dan3bxjue8c'
package-name: 'nuxt-app'
package-dist-directory: './nuxt-app/.output/public'
bucket-name-preview: 'pie-aperture-preview'
bucket-name-main: 'pie-aperture'
secrets: inherit
browser-tests:
needs: 'build-deploy-nuxt-app-ubuntu-node20'
name: Run System / Visual Tests
runs-on: ubuntu-latest
steps:
# Checkout the Repo
- name: Checkout
uses: actions/checkout@v3
# Setup Node
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: "yarn"
- name: Install Dependencies
shell: bash
run: yarn
# Setup Playwright
- name: Setup Playwright
uses: ./.github/actions/setup-playwright
- name: Run SSR Tests
shell: bash
run: yarn test:ssr --filter=nuxt-app
# TODO - fix this test in DSW-2157
# - name: Run System Tests
# shell: bash
# run: yarn test:system --filter=nuxt-app
- uses: actions/upload-artifact@v3
if: always()
with:
name: nuxt-playwright-report
path: playwright-reports/nuxt-app-playwright-report/
retention-days: 7
# TODO - fix this test in DSW-2158
# - name: Run Percy Tests
# shell: bash
# run: yarn test:visual --filter=nuxt-app
env:
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
NUXT_AMPLIFY_ID: d36dan3bxjue8c
PERCY_TOKEN_PIE_APERTURE_NUXT: ${{ secrets.PERCY_TOKEN_PIE_APERTURE_NUXT }}
PR_NUMBER: ${{ github.event.number }}