mirror of
https://github.com/nodejs/node.git
synced 2026-11-27 17:52:27 -05:00
test: fix addons and node-api test assumptions
PR-URL: https://github.com/nodejs/node/pull/55441 Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
3 files changed
+5
-13
No files matched your search
@@ -12,12 +12,9 @@ if (process.config.variables.node_without_node_options) {
|
||||
const uvThreadPoolPath = '../../fixtures/dotenv/uv-threadpool.env';
|
||||
|
||||
// Should update UV_THREADPOOL_SIZE
|
||||
let filePath = path.join(__dirname, `./build/${common.buildType}/test_uv_threadpool_size`);
|
||||
if (common.isWindows) {
|
||||
filePath = filePath.replaceAll('\\', '\\\\');
|
||||
}
|
||||
const filePath = path.join(__dirname, `./build/${common.buildType}/test_uv_threadpool_size`);
|
||||
const code = `
|
||||
const { test } = require('${filePath}');
|
||||
const { test } = require(${JSON.stringify(filePath)});
|
||||
const size = parseInt(process.env.UV_THREADPOOL_SIZE, 10);
|
||||
require('assert').strictEqual(size, 4);
|
||||
test(size);
|
||||
|
||||
Reference in new issue
Block a user