-
Notifications
You must be signed in to change notification settings - Fork 4
117 lines (95 loc) · 2.85 KB
/
ui-tasks.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
name: UI
on: [push]
env:
NEXT_PUBLIC_VERCEL_GIT_COMMIT_REF: int
NEXT_PUBLIC_BASE_URL: https://int.octopus.ac
NEXT_PUBLIC_MEDIA_BUCKET: https://science-octopus-publishing-images-int.s3.eu-west-1.amazonaws.com
NEXT_PUBLIC_SITEMAP_BUCKET: https://science-octopus-publishing-sitemaps-int.s3.eu-west-1.amazonaws.com
NEXT_PUBLIC_ORCID_APP_ID: APP-GXJE14DWV9NGHP5T
NEXT_PUBLIC_ORCID_AUTH_URL: https://sandbox.orcid.org/oauth
NEXT_PUBLIC_CONTENTFUL_SPACE_ID: ${{secrets.NEXT_PUBLIC_CONTENTFUL_SPACE_ID}}
NEXT_PUBLIC_CONTENTFUL_ACCESS_TOKEN: ${{secrets.NEXT_PUBLIC_CONTENTFUL_ACCESS_TOKEN}}
jobs:
prettier:
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node 20.x Environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
- name: Install dependencies
working-directory: ./ui
run: npm ci
- name: Run prettier check
working-directory: ./ui
run: npm run format:check
eslint:
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node 20.x Environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
- name: Install dependencies
working-directory: ./ui
run: npm ci
- name: Run lint
working-directory: ./ui
run: npm run lint
lighthouseci:
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node 20.x Environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
- name: Install dependencies
working-directory: ./ui
run: npm ci && npm install -g @lhci/[email protected]
- name: Run build
working-directory: ./ui
run: npm run build
- name: Run lighthouseCI
working-directory: ./ui
run: lhci autorun
ui-tests:
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node 20.x Environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
- name: Install dependencies
working-directory: ./ui
run: npm ci
- name: Run Unit tests
working-directory: ./ui
run: npm run test
typescript-lint:
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node 20.x Environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
- name: Install dependencies
working-directory: ./ui
run: npm ci
- name: Run tsc to check for typescript errors
working-directory: ./ui
run: tsc