GeezerVison is showing github.com — test: remove unnecessary syscall to cpuinfo · nodejs/node@60c8fc0
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: test/common/index.js +3-3Lines changed: 3 additions & 3 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -124,7 +124,7 @@ const isMacOS = process.platform === 'darwin'; |
124 | 124 | const isASan = process.config.variables.asan === 1; |
125 | 125 | const isRiscv64 = process.arch === 'riscv64'; |
126 | 126 | const isDebug = process.features.debug; |
127 | | -const isPi = (() => { |
| 127 | +function isPi() { |
128 | 128 | try { |
129 | 129 | // Normal Raspberry Pi detection is to find the `Raspberry Pi` string in |
130 | 130 | // the contents of `/sys/firmware/devicetree/base/model` but that doesn't |
@@ -136,7 +136,7 @@ const isPi = (() => { |
136 | 136 | } catch { |
137 | 137 | return false; |
138 | 138 | } |
139 | | -})(); |
| 139 | +} |
140 | 140 |
|
141 | 141 | // When using high concurrency or in the CI we need much more time for each connection attempt |
142 | 142 | net.setDefaultAutoSelectFamilyAttemptTimeout(platformTimeout(net.getDefaultAutoSelectFamilyAttemptTimeout() * 10)); |
@@ -256,7 +256,7 @@ function platformTimeout(ms) { |
256 | 256 | if (exports.isAIX || exports.isIBMi) |
257 | 257 | return multipliers.two * ms; // Default localhost speed is slower on AIX |
258 | 258 |
|
259 | | - if (isPi) |
| 259 | + if (isPi()) |
260 | 260 | return multipliers.two * ms; // Raspberry Pi devices |
261 | 261 |
|
262 | 262 | if (isRiscv64) { |
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-crypto-dh-hash.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -26,7 +26,7 @@ if (!common.hasCrypto) { |
26 | 26 | common.skip('node compiled without OpenSSL.'); |
27 | 27 | } |
28 | 28 |
|
29 | | -if (common.isPi) { |
| 29 | +if (common.isPi()) { |
30 | 30 | common.skip('Too slow for Raspberry Pi devices'); |
31 | 31 | } |
32 | 32 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-crypto-dh-keys.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -26,7 +26,7 @@ if (!common.hasCrypto) { |
26 | 26 | common.skip('node compiled without OpenSSL.'); |
27 | 27 | } |
28 | 28 |
|
29 | | -if (common.isPi) { |
| 29 | +if (common.isPi()) { |
30 | 30 | common.skip('Too slow for Raspberry Pi devices'); |
31 | 31 | } |
32 | 32 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-dh-regr.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -26,7 +26,7 @@ if (!common.hasCrypto) { |
26 | 26 | common.skip('missing crypto'); |
27 | 27 | } |
28 | 28 |
|
29 | | -if (common.isPi) { |
| 29 | +if (common.isPi()) { |
30 | 30 | common.skip('Too slow for Raspberry Pi devices'); |
31 | 31 | } |
32 | 32 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-fs-watch-system-limit.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -9,7 +9,7 @@ if (!common.isLinux) { |
9 | 9 | common.skip('The fs watch limit is OS-dependent'); |
10 | 10 | } |
11 | 11 |
|
12 | | -if (common.isPi) { |
| 12 | +if (common.isPi()) { |
13 | 13 | common.skip('Too slow for Raspberry Pi devices'); |
14 | 14 | } |
15 | 15 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-hash-seed.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
|
3 | 3 | // Check that spawn child doesn't create duplicated entries |
4 | 4 | const common = require('../common'); |
5 | 5 |
|
6 | | -if (common.isPi) { |
| 6 | +if (common.isPi()) { |
7 | 7 | common.skip('Too slow for Raspberry Pi devices'); |
8 | 8 | } |
9 | 9 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-heapsnapshot-near-heap-limit-bounded.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
|
2 | 2 |
|
3 | 3 | const common = require('../common'); |
4 | 4 |
|
5 | | -if (common.isPi) { |
| 5 | +if (common.isPi()) { |
6 | 6 | common.skip('Too slow for Raspberry Pi devices'); |
7 | 7 | } |
8 | 8 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-heapsnapshot-near-heap-limit-by-api.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
|
3 | 3 |
|
4 | 4 | const common = require('../common'); |
5 | 5 |
|
6 | | -if (common.isPi) { |
| 6 | +if (common.isPi()) { |
7 | 7 | common.skip('Too slow for Raspberry Pi devices'); |
8 | 8 | } |
9 | 9 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-heapsnapshot-near-heap-limit.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
|
2 | 2 |
|
3 | 3 | const common = require('../common'); |
4 | 4 |
|
5 | | -if (common.isPi) { |
| 5 | +if (common.isPi()) { |
6 | 6 | common.skip('Too slow for Raspberry Pi devices'); |
7 | 7 | } |
8 | 8 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: test/pummel/test-next-tick-infinite-calls.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
|
22 | 22 | 'use strict'; |
23 | 23 | const common = require('../common'); |
24 | 24 |
|
25 | | -if (common.isPi) { |
| 25 | +if (common.isPi()) { |
26 | 26 | common.skip('Too slow for Raspberry Pi devices'); |
27 | 27 | } |
28 | 28 |
|
|