Skip to content

Commit

Permalink
test: improve assertion message for test-vm-memleak
Browse files Browse the repository at this point in the history
The test is unreliable in CI. It might be helpful to get an exact read
of `rss` so this adds that to the assertion message.
  • Loading branch information
Trott committed Jan 23, 2021
1 parent 2242cbb commit 7454aff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/pummel/test-vm-memleak.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const interval = setInterval(function() {

const rss = process.memoryUsage.rss();
assert.ok(rss < 64 * 1024 * 1024,
`memory usage: ${Math.round(rss / (1024 * 1024))}Mb`);
`memory usage: ${rss} (${Math.round(rss / (1024 * 1024))} MB)`);

// Stop after 5 seconds.
if (Date.now() - start > 5 * 1000) {
Expand Down

0 comments on commit 7454aff

Please sign in to comment.