|
1 | | -name: Node CI |
| 1 | +name: CI - cli |
2 | 2 |
|
3 | 3 | on: |
| 4 | + workflow_dispatch: |
4 | 5 | pull_request: |
5 | 6 | branches: |
6 | 7 | - '*' |
7 | 8 | push: |
8 | 9 | branches: |
9 | 10 | - latest |
10 | | - workflow_dispatch: |
11 | 11 |
|
12 | 12 | jobs: |
13 | 13 | lint: |
14 | 14 | runs-on: ubuntu-latest |
15 | 15 | steps: |
16 | | - # Checkout the npm/cli repo |
17 | | - - uses: actions/checkout@v2 |
18 | | - - name: Use Node.js 14.x |
19 | | - uses: actions/setup-node@v2 |
| 16 | + - uses: actions/checkout@v3 |
| 17 | + - name: Use Node.js 16.x |
| 18 | + uses: actions/setup-node@v3 |
20 | 19 | with: |
21 | | - node-version: 14.x |
| 20 | + node-version: 16.x |
22 | 21 | cache: npm |
23 | | - - name: Install dependencies |
24 | | - run: | |
25 | | - node ./bin/npm-cli.js install --ignore-scripts --no-audit |
26 | | - node ./bin/npm-cli.js rebuild |
27 | | - - name: Run linting |
28 | | - run: node ./bin/npm-cli.js run posttest |
29 | | - env: |
30 | | - DEPLOY_VERSION: testing |
| 22 | + - run: node ./bin/npm-cli.js run resetdeps |
| 23 | + - run: node ./bin/npm-cli.js run lint |
31 | 24 |
|
32 | 25 | check_docs: |
33 | 26 | runs-on: ubuntu-latest |
34 | 27 | steps: |
35 | | - - uses: actions/checkout@v2 |
36 | | - - name: Use Node.js 14.x |
37 | | - uses: actions/setup-node@v2 |
| 28 | + - uses: actions/checkout@v3 |
| 29 | + - name: Use Node.js 16.x |
| 30 | + uses: actions/setup-node@v3 |
38 | 31 | with: |
39 | | - node-version: 14.x |
| 32 | + node-version: 16.x |
40 | 33 | cache: npm |
41 | | - - name: Install dependencies |
42 | | - run: | |
43 | | - node ./bin/npm-cli.js install --ignore-scripts --no-audit |
44 | | - - name: Rebuild the docs |
45 | | - run: make freshdocs |
46 | | - - name: Git should not be dirty |
47 | | - run: node scripts/git-dirty.js |
48 | | - |
| 34 | + - run: make freshdocs |
| 35 | + - run: node scripts/git-dirty.js |
49 | 36 |
|
50 | 37 | licenses: |
51 | 38 | runs-on: ubuntu-latest |
52 | 39 | steps: |
53 | | - # Checkout the npm/cli repo |
54 | | - - uses: actions/checkout@v2 |
55 | | - - name: Use Node.js 14.x |
56 | | - uses: actions/setup-node@v2 |
| 40 | + - uses: actions/checkout@v3 |
| 41 | + - name: Use Node.js 16.x |
| 42 | + uses: actions/setup-node@v3 |
57 | 43 | with: |
58 | | - node-version: 14.x |
| 44 | + node-version: 16.x |
59 | 45 | cache: npm |
60 | | - - name: Install dependencies |
61 | | - run: | |
62 | | - node ./bin/npm-cli.js install --ignore-scripts --no-audit |
63 | | - node ./bin/npm-cli.js rebuild |
64 | | - - name: Validate licenses |
65 | | - run: node ./bin/npm-cli.js run licenses |
| 46 | + - run: node ./bin/npm-cli.js run resetdeps |
| 47 | + - run: node ./bin/npm-cli.js run licenses |
66 | 48 |
|
67 | 49 | smoke-tests: |
68 | 50 | strategy: |
69 | 51 | fail-fast: false |
70 | 52 | matrix: |
71 | | - node-version: [12.x, 14.x, 16.x] |
| 53 | + node-version: |
| 54 | + - 12.x |
| 55 | + - 14.x |
| 56 | + - 16.x |
72 | 57 | platform: |
73 | 58 | - os: ubuntu-latest |
74 | 59 | shell: bash |
75 | 60 | - os: macos-latest |
76 | 61 | shell: bash |
77 | 62 | - os: windows-latest |
78 | | - shell: bash |
79 | | - - os: windows-latest |
80 | | - shell: powershell |
81 | | - |
| 63 | + shell: cmd |
82 | 64 | runs-on: ${{ matrix.platform.os }} |
83 | 65 | defaults: |
84 | 66 | run: |
85 | 67 | shell: ${{ matrix.platform.shell }} |
86 | | - |
87 | 68 | steps: |
88 | | - # Checkout the npm/cli repo |
89 | | - - uses: actions/checkout@v2 |
90 | | - |
91 | | - # Installs the specific version of Node.js |
| 69 | + - uses: actions/checkout@v3 |
92 | 70 | - name: Use Node.js ${{ matrix.node-version }} |
93 | | - uses: actions/setup-node@v2 |
| 71 | + uses: actions/setup-node@v3 |
94 | 72 | with: |
95 | 73 | node-version: ${{ matrix.node-version }} |
96 | 74 | cache: npm |
97 | | - |
98 | | - # Run the installer script |
99 | | - - name: Install dependencies |
100 | | - run: | |
101 | | - node ./bin/npm-cli.js install --ignore-scripts --no-audit |
102 | | - node ./bin/npm-cli.js rebuild |
103 | | -
|
104 | | - # Run the smoke tests |
105 | | - - name: Run Smoke tests |
106 | | - run: node ./bin/npm-cli.js run --ignore-scripts smoke-tests -- --no-check-coverage -t600 -Rbase -c |
107 | | - env: |
108 | | - DEPLOY_VERSION: testing |
| 75 | + - run: node ./bin/npm-cli.js run resetdeps |
| 76 | + - run: node ./bin/npm-cli.js run smoke-tests --ignore-scripts |
| 77 | + - name: git status |
| 78 | + if: matrix.platform.os != 'windows-latest' |
| 79 | + run: node scripts/git-dirty.js |
109 | 80 |
|
110 | 81 | test: |
111 | 82 | strategy: |
112 | 83 | fail-fast: false |
113 | 84 | matrix: |
114 | | - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] |
| 85 | + node-version: |
| 86 | + - 12.13.0 |
| 87 | + - 12.x |
| 88 | + - 14.15.0 |
| 89 | + - 14.x |
| 90 | + - 16.0.0 |
| 91 | + - 16.x |
115 | 92 | platform: |
116 | 93 | - os: ubuntu-latest |
117 | 94 | shell: bash |
118 | 95 | - os: macos-latest |
119 | 96 | shell: bash |
120 | 97 | - os: windows-latest |
121 | | - shell: bash |
122 | | - - os: windows-latest |
123 | | - shell: powershell |
124 | | - |
| 98 | + shell: cmd |
125 | 99 | runs-on: ${{ matrix.platform.os }} |
126 | 100 | defaults: |
127 | 101 | run: |
128 | 102 | shell: ${{ matrix.platform.shell }} |
129 | | - |
130 | 103 | steps: |
131 | | - # Checkout the npm/cli repo |
132 | | - - uses: actions/checkout@v2 |
133 | | - |
134 | | - # Installs the specific version of Node.js |
| 104 | + - uses: actions/checkout@v3 |
135 | 105 | - name: Use Node.js ${{ matrix.node-version }} |
136 | | - uses: actions/setup-node@v2 |
| 106 | + uses: actions/setup-node@v3 |
137 | 107 | with: |
138 | 108 | node-version: ${{ matrix.node-version }} |
139 | 109 | cache: npm |
140 | | - |
141 | | - # Run the installer script |
142 | | - - name: Install dependencies |
143 | | - run: | |
144 | | - node ./bin/npm-cli.js install --ignore-scripts --no-audit |
145 | | - node ./bin/npm-cli.js rebuild |
146 | | -
|
147 | | - # Run the tests |
148 | | - - name: Run Tap tests |
149 | | - run: node ./bin/npm-cli.js run test --ignore-scripts -- -t600 -Rbase -c |
| 110 | + - run: node ./bin/npm-cli.js run resetdeps |
| 111 | + - run: node ./bin/npm-cli.js run test --ignore-scripts |
| 112 | + - name: git status |
| 113 | + if: matrix.platform.os != 'windows-latest' |
| 114 | + run: node scripts/git-dirty.js |
0 commit comments