Skip to content

Commit

Permalink
test: increase slop limit in memory leak test
Browse files Browse the repository at this point in the history
It transpires that the extra bookkeeping in debug builds sometimes makes
the increase in RSS go _just_ over the 5 MB limit, by fewer than 100 kB.
Double the limit so we hopefully don't run into it any time again soon.

The memory leak it tests for was one where RSS grew by hundreds of
megabytes over the lifetime of the test; 5 vs. 10 MB is insignificant.

Fixes: #21076

PR-URL: #21080
Refs: #21076
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Anatoli Papirovski <[email protected]>
Reviewed-By: Сковорода Никита Андреевич <[email protected]>
Reviewed-By: Yuta Hiroto <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Tiancheng "Timothy" Gu <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
  • Loading branch information
bnoordhuis authored and Trott committed Jun 3, 2018
1 parent b557a3b commit 997e97d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/parallel/test-crypto-dh-leak.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ const after = process.memoryUsage().rss;

// RSS should stay the same, ceteris paribus, but allow for
// some slop because V8 mallocs memory during execution.
assert(after - before < 5 << 20, `before=${before} after=${after}`);
assert(after - before < 10 << 20, `before=${before} after=${after}`);

0 comments on commit 997e97d

Please sign in to comment.