-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathwin.yml
More file actions
49 lines (49 loc) · 1.33 KB
/
win.yml
File metadata and controls
49 lines (49 loc) · 1.33 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
environment:
matrix:
- nodejs_version: "14"
- nodejs_version: "12"
cache:
- node_modules
install:
# Install Node.js
- ps: >-
try { Install-Product node $env:nodejs_version -ErrorAction Stop }
catch { Update-NodeJsInstallation (Get-NodeJsLatestBuild $env:nodejs_version) }
# Configure npm
- npm install -g npm@latest
- ps: |
# Skip updating shrinkwrap / lock
npm config set shrinkwrap false
# Remove all non-test dependencies
- ps: |
# Remove example dependencies
npm rm --silent --save-dev connect-redis --no-optional
# Setup Node.js version-specific dependencies
- ps: |
npm --version
npm install fsevents@latest -f --save-optional
# mocha for testing
npm install expect --save-dev --no-optional
npm install superagent --save-dev --no-optional
npm install socket.io-client --save-dev --no-optional
npm install socket.io --save-dev --no-optional
# Update Node.js modules
- ps: |
# Prune & rebuild node_modules
if (Test-Path -Path node_modules) {
npm prune
npm rebuild
}
# Install Node.js modules
- npm install --no-optional
build: off
test_script:
# Output version data
- ps: |
node --version
npm --version
# Run test script
- npm run test:cov
# Run linting
- npm run lint
version: "{build}"