-
Notifications
You must be signed in to change notification settings - Fork 132
120 lines (98 loc) · 3.97 KB
/
e2e-win.yml
File metadata and controls
120 lines (98 loc) · 3.97 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
name: E2E Windows
on: [workflow_call]
jobs:
windows:
runs-on: windows-latest
timeout-minutes: 180
env:
TEST_MODE: true
E2E: true
IS_CI: true
steps:
- uses: actions/checkout@v5
with:
submodules: 'recursive'
- name: "Setup environment"
uses: ./.github/actions/setup-env
with:
cachePrefix: "e2e-crossplatform-windows"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle,e2e-tests,helia,@quiet/node-common"
- name: "Fetch jsign"
shell: bash
run: cd packages/desktop && curl https://zbay-binaries.s3.us-east-2.amazonaws.com/jsign/jsign-2.1.jar --output ./jsign-2.1.jar
- name: "Remove test files workaround (jest types conflicting with cypress types)"
run: find packages/desktop/src -name '*.test.*' -delete
shell: bash
- name: Before build
uses: ./.github/actions/before-build
with:
source-path: win32
envfile: .env.e2e
- name: electron-builder
working-directory: ./packages/desktop
run: node_modules/.bin/electron-builder --win
shell: bash
- name: Extract version
id: extract_version
uses: Saionaro/extract-package-version@fdb5b74adc1278ddb777dfed4c988b9d098bb48d # v1.2.1
with:
path: packages/desktop
- name: FILE_NAME env
working-directory: ./packages/desktop/dist
run: echo "FILE_NAME=Quiet Setup ${{ steps.extract_version.outputs.version }}.exe" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
shell: powershell
- name: Chmod
working-directory: ./packages/desktop/dist
run: chmod +x "$FILE_NAME"
shell: bash
- name: "Upload built app"
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
with:
name: quiet-windows
path: ./packages/desktop/dist/Quiet Setup ${{ steps.extract_version.outputs.version }}.exe
retention-days: 2
- name: Install exe
run: Start-Process "Quiet Setup ${{ steps.extract_version.outputs.version }}.exe" -Wait
working-directory: ./packages/desktop/dist
shell: powershell
- name: Check if Quiet installed properly
run: Get-ChildItem -Path C:\Users\runneradmin\AppData\Local\Programs\@quietdesktop
shell: powershell
- name: Kill Quiet
run: Get-Process -Name "Quiet" -ErrorAction SilentlyContinue | Stop-Process -Force
shell: powershell
if: always()
- name: Kill tor
run: Get-Process -Name "tor" -ErrorAction SilentlyContinue | Stop-Process -Force
shell: powershell
- name: Delay
run: Start-Sleep -Seconds 10
shell: powershell
- name: Run one client test
uses: nick-fields/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2.9.0
with:
timeout_minutes: 15
max_attempts: 3
shell: bash
command: cd packages/e2e-tests && npm run test oneClient.test.ts
- name: Run user profile test
uses: nick-fields/retry@v2
with:
timeout_minutes: 25
max_attempts: 3
shell: bash
command: cd packages/e2e-tests && npm run test userProfile.test.ts
- name: Run multiple clients test
uses: nick-fields/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2.9.0
with:
timeout_minutes: 30
max_attempts: 3
shell: bash
command: cd packages/e2e-tests && npm run test multipleClients.test.ts
- name: Run invitation link test - Includes 2 separate application clients
uses: nick-fields/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2.9.0
with:
timeout_minutes: 10
max_attempts: 3
shell: bash
command: cd packages/e2e-tests && npm run test invitationLink.test.ts