-
-
Notifications
You must be signed in to change notification settings - Fork 104
62 lines (51 loc) · 1.33 KB
/
test-windows.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
name: ' 🧪 Test Windows'
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
paths-ignore:
- 'docs/**'
permissions:
contents: read
jobs:
test-os:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version:
- 18.x
- 20.x
- 22.x
- 23.x
os:
- windows-latest
# - macos-latest # Smoke test is enough for now.
steps:
- uses: actions/checkout@v4
- name: Where is corepack
run: where corepack
shell: bash
- name: Where is corepack power shell
if: runner.os == 'Windows'
run: (Get-Command corepack.exe).Path
shell: pwsh
- name: Clear hosted toolcache for corepack
if: runner.os == 'Windows'
run: Remove-Item -Recurse -Force "C:\hostedtoolcache\windows\node\$nodeVersion\x64\corepack*"
shell: pwsh
- name: Setup pnpm
uses: pnpm/action-setup@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4.2.0
with:
registry-url: 'https://registry.npmjs.org'
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
- name: Enable Corepack
run: |
npm i -g --force corepack
corepack enable
pnpm -v
shell: bash