Skip to content

Commit 47840cc

Browse files
committed
test: Buffer.allowUnsafe on different versions
1 parent 3ddbea1 commit 47840cc

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Test Buffer.allocUnsafe
2+
3+
on:
4+
push:
5+
6+
concurrency:
7+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
8+
cancel-in-progress: true
9+
10+
permissions: {}
11+
12+
jobs:
13+
example_matrix:
14+
strategy:
15+
matrix:
16+
version: [10, 12, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25]
17+
os: [ubuntu-latest, windows-latest]
18+
runs-on: ${{ matrix.os }}
19+
steps:
20+
- uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
21+
with:
22+
node-version: ${{ matrix.version }}
23+
- run: |
24+
node -p '({
25+
containsRandomData: Buffer.allocUnsafe(2 ** 10).some(v => v !== 0),
26+
platform: process.platform,
27+
version: process.version,
28+
snapshotEnabled: process.config.variables.node_use_node_snapshot,
29+
})' >> "$${{ matrix.os == 'windows-latest' && 'env:' || '' }}GITHUB_STEP_SUMMARY"

0 commit comments

Comments
 (0)