Skip to content

Commit

Permalink
[test] Fix merge + skip test_uv_threadpool_size/node-options
Browse files Browse the repository at this point in the history
  • Loading branch information
victorgomes committed Apr 23, 2024
1 parent 4cec27a commit 60a00a8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 11 deletions.
3 changes: 3 additions & 0 deletions test/node-api/node-api.status
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ prefix node-api

[true] # This section applies to all platforms

# NODE_OPTIONS do not seem to work with GN.
test_uv_threadpool_size/node-options: SKIP

[$system==win32]

[$system==solaris] # Also applies to SmartOS
Expand Down
3 changes: 0 additions & 3 deletions test/parallel/test-buffer-alloc.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,13 @@ const {
kMaxLength,
} = require('buffer');

<<<<<<< HEAD
// Verify the maximum Uint8Array size. There is no concrete limit by spec. The
// internal limits should be updated if this fails.
assert.throws(
() => new Uint8Array(kMaxLength + 1),
{ message: `Invalid typed array length: ${kMaxLength + 1}` },
);

=======
>>>>>>> b3e1523f34 (Adapt tests for increased TypedArray sizes (#161))
const b = Buffer.allocUnsafe(1024);
assert.strictEqual(b.length, 1024);

Expand Down
11 changes: 3 additions & 8 deletions test/parallel/test-buffer-tostring-rangeerror.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,7 @@ require('../common');
// Regression test for https://github.com/nodejs/node/issues/649.

const assert = require('assert');
const {
SlowBuffer,
constants: {
MAX_STRING_LENGTH,
},
} = require('buffer');
const SlowBuffer = require('buffer').SlowBuffer;

// Find the maximum supported buffer length.
let limit = 1 << 31; // 2GB
Expand All @@ -25,8 +20,8 @@ while (true) {
}

const message = {
code: 'ERR_STRING_TOO_LONG',
name: 'Error',
code: 'ERR_OUT_OF_RANGE',
name: 'RangeError',
};
assert.throws(() => Buffer(limit).toString('utf8'), message);
assert.throws(() => SlowBuffer(limit).toString('utf8'), message);
Expand Down

0 comments on commit 60a00a8

Please sign in to comment.