Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions test/parallel/test-vm-timeout.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ assert.throws(function() {
// Test 2: Timeout must be >= 0ms
assert.throws(function() {
vm.runInThisContext('', { timeout: -1 });
}, RangeError);
}, /^RangeError: timeout must be a positive number$/);

// Test 3: Timeout of 0ms
assert.throws(function() {
vm.runInThisContext('', { timeout: 0 });
}, RangeError);
}, /^RangeError: timeout must be a positive number$/);

// Test 4: Timeout of 1000ms, script finishes first
vm.runInThisContext('', { timeout: 1000 });
Expand Down