-
Notifications
You must be signed in to change notification settings - Fork 452
125 lines (109 loc) · 3.55 KB
/
e2e-tests.yml
File metadata and controls
125 lines (109 loc) · 3.55 KB
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
125
---
name: E2E Tests
on:
push:
branches: [main]
pull_request:
branches:
- '**'
- '!release-please--**'
schedule:
# check daily to notice potential package manager issues
- cron: '0 1 * * *' # At 01:00 daily
jobs:
e2e-windows:
name: E2E Windows tests
runs-on: ${{ matrix.os }}
timeout-minutes: 20
strategy:
matrix:
os: [windows-2025]
# Pinning 20.x version as a temporary workaround due to this https://github.com/nodejs/node/issues/52884
node-version: ['20.12.2', '22', '24']
fail-fast: false
steps:
# This improves Windows network performance. We need this since we open many ports in our tests.
- name: Increase Windows port limit and reduce time wait delay
run: |
netsh int ipv4 set dynamicport tcp start=1025 num=64511
REG ADD HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters /v TcpTimedWaitDelay /t REG_DWORD /d 30 /f
- name: Git checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup node
uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node-version }}
cache: npm
check-latest: true
# Let corepack manage npm, pnpm, and yarn versions for E2E tests
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: npm ci --no-audit
- name: Build project
run: npm run build
- name: Run E2E tests
run: npm run test:e2e
- name: Notify Slack
uses: 8398a7/action-slack@v3
if: ${{ github.event_name == 'schedule' && failure() }}
with:
status: custom
fields: workflow
custom_payload: |
{
attachments: [{
title: 'E2E Test Failed! (${{ matrix.os }},node-${{ matrix.node-version }}',
color: 'danger',
text: `${process.env.AS_WORKFLOW}\n\nEither something broke or a test is flaky.\n\nConsider doing something about it :fire_engine:`,
}]
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
e2e-linux-based-os:
name: E2E
runs-on: ${{ matrix.os }}
timeout-minutes: 10
strategy:
matrix:
os: [ubuntu-latest, macOS-latest]
node-version: ['20.12.2', '22', '24']
fail-fast: false
steps:
- name: Git checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup node
uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node-version }}
cache: npm
check-latest: true
- uses: pnpm/action-setup@v4
with:
version: 10
- name: Install dependencies
run: npm ci --no-audit
- name: Build project
run: npm run build
- name: Run E2E tests
run: npm run test:e2e
- name: Notify Slack
uses: 8398a7/action-slack@v3
if: ${{ github.event_name == 'schedule' && failure() }}
with:
status: custom
fields: workflow
custom_payload: |
{
attachments: [{
title: 'E2E Test Failed! (${{ matrix.os }},node-${{ matrix.node-version }}',
color: 'danger',
text: `${process.env.AS_WORKFLOW}\n\nEither something broke or a test is flaky.\n\nConsider doing something about it :fire_engine:`,
}]
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}