Skip to content

Commit

Permalink
test: fix flaky test-vm-timeout-escape-queuemicrotask
Browse files Browse the repository at this point in the history
Use a larger timeout on slower platforms so that the timeout doesn't
fire before the error condition occurs.

PR-URL: #24296
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
  • Loading branch information
Trott committed Nov 13, 2018
1 parent 05a11d1 commit 8e3c5b5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion test/known_issues/known_issues.status
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ prefix known_issues

[$system==linux]
test-vm-timeout-escape-promise: PASS,FLAKY
test-vm-timeout-escape-queuemicrotask: PASS,FLAKY

[$system==macos]

Expand Down
4 changes: 2 additions & 2 deletions test/known_issues/test-vm-timeout-escape-queuemicrotask.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
// Promises, nextTick, and queueMicrotask allow code to escape the timeout
// set for runInContext, runInNewContext, and runInThisContext

require('../common');
const common = require('../common');
const assert = require('assert');
const vm = require('vm');

Expand Down Expand Up @@ -32,7 +32,7 @@ assert.throws(() => {
queueMicrotask,
loop
},
{ timeout: 5 }
{ timeout: common.platformTimeout(5) }
);
}, {
code: 'ERR_SCRIPT_EXECUTION_TIMEOUT',
Expand Down

0 comments on commit 8e3c5b5

Please sign in to comment.