@@ -31,12 +31,11 @@ jobs:
31
31
strip -x *.node
32
32
- host : ubuntu-latest
33
33
target : x86_64-unknown-linux-gnu
34
- docker : ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-alpine-zig
34
+ docker : ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian
35
35
build : |-
36
36
set -e &&
37
- rustup target add x86_64-unknown-linux-gnu &&
38
37
yarn build --target x86_64-unknown-linux-gnu &&
39
- llvm- strip -x *.node
38
+ strip *.node
40
39
- host : macos-latest
41
40
target : aarch64-apple-darwin
42
41
build : |
92
91
if : ${{ matrix.settings.setup }}
93
92
shell : bash
94
93
- name : Install dependencies
95
- run : yarn install --ignore-scripts --frozen-lockfile --registry https://registry.npmjs.org --network-timeout 300000
94
+ run : yarn install
96
95
- name : Build in docker
97
96
uses : addnab/docker-run-action@v3
98
97
if : ${{ matrix.settings.docker }}
@@ -136,7 +135,7 @@ jobs:
136
135
path : node_modules
137
136
key : npm-cache-test-linux-x64-gnu-${{ matrix.node }}-${{ hashFiles('yarn.lock') }}
138
137
- name : Install dependencies
139
- run : yarn install --ignore-scripts --frozen-lockfile --registry https://registry.npmjs.org --network-timeout 300000
138
+ run : yarn install
140
139
- name : Download artifacts
141
140
uses : actions/download-artifact@v3
142
141
with :
@@ -146,12 +145,53 @@ jobs:
146
145
run : ls -R .
147
146
shell : bash
148
147
- name : Test bindings
149
- run : docker run --rm -v $(pwd):/build -w /build node:${{ matrix.node }}-slim yarn test
148
+ run : docker run --rm -v $(pwd):/build -w /build node:${{ matrix.node }}-slim
149
+ test-macOS-binding :
150
+ name : Test bindings on ${{ matrix.settings.target }} - node@${{ matrix.node }}
151
+ needs :
152
+ - build
153
+ strategy :
154
+ fail-fast : false
155
+ matrix :
156
+ settings :
157
+ - host : macos-latest
158
+ target : x86_64-apple-darwin
159
+ node :
160
+ - ' 14'
161
+ - ' 16'
162
+ - ' 18'
163
+ runs-on : ${{ matrix.settings.host }}
164
+ steps :
165
+ - uses : actions/checkout@v3
166
+ - name : Setup node
167
+ uses : actions/setup-node@v3
168
+ with :
169
+ node-version : ${{ matrix.node }}
170
+ check-latest : true
171
+ cache : yarn
172
+ - name : Cache NPM dependencies
173
+ uses : actions/cache@v3
174
+ with :
175
+ path : .yarn/cache
176
+ key : npm-cache-test-${{ matrix.settings.target }}-${{ matrix.node }}-${{ hashFiles('yarn.lock') }}
177
+ - name : Install dependencies
178
+ run : yarn install
179
+ - name : Download artifacts
180
+ uses : actions/download-artifact@v3
181
+ with :
182
+ name : bindings-${{ matrix.settings.target }}
183
+ path : .
184
+ - name : List packages
185
+ run : ls -R .
186
+ shell : bash
187
+ - name : Test bindings
188
+ run : yarn test
150
189
publish :
151
190
name : Publish
152
191
runs-on : ubuntu-latest
153
192
needs :
154
193
- test-linux-x64-gnu-binding
194
+ - test-macOS-binding
155
195
steps :
156
196
- uses : actions/checkout@v3
157
197
- name : Setup node
@@ -168,7 +208,7 @@ jobs:
168
208
restore-keys : |
169
209
npm-cache-
170
210
- name : Install dependencies
171
- run : yarn install --ignore-scripts --frozen-lockfile --registry https://registry.npmjs.org --network-timeout 300000
211
+ run : yarn install
172
212
- name : Download all artifacts
173
213
uses : actions/download-artifact@v3
174
214
with :
0 commit comments