Skip to content

Commit 5f252a4

Browse files
authored
test: skip test-buffer-tostring-rangeerror when low on memory
This has shown up as RangeError: Array buffer allocation failed and it should be totally fine to skip this test in case the memory is low. PR-URL: #58142 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: LiviaMedeiros <livia@cirno.name> Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 0050add commit 5f252a4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

test/parallel/test-buffer-tostring-rangeerror.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,15 @@
11
'use strict';
2-
require('../common');
2+
3+
const common = require('../common');
34

45
// This test ensures that Node.js throws an Error when trying to convert a
56
// large buffer into a string.
67
// Regression test for https://github.com/nodejs/node/issues/649.
78

9+
if (!common.enoughTestMem) {
10+
common.skip('skipped due to memory requirements');
11+
}
12+
813
const assert = require('assert');
914
const {
1015
Buffer,

0 commit comments

Comments
 (0)