diff options
author | akira.xue <akira.xue@guanaitong.com> | 2017-07-16 15:10:37 +0800 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2017-07-16 06:59:12 -0700 |
commit | e8170f2246717cd8171c450ba11ae04934cf7dd9 (patch) | |
tree | c2c0d60aaf3410bd8a57e37a358b7eee2c656b90 /test/parallel/test-vm-create-context-arg.js | |
parent | bfae1feb38ee69e0e9f61d560c50c7325c221a72 (diff) | |
download | android-node-v8-e8170f2246717cd8171c450ba11ae04934cf7dd9.tar.gz android-node-v8-e8170f2246717cd8171c450ba11ae04934cf7dd9.tar.bz2 android-node-v8-e8170f2246717cd8171c450ba11ae04934cf7dd9.zip |
test: use regluar expression in vm test
update test/parallel/test-vm-create-context-arg.js
in line 27 to change `TypeError` to the regular expression
with the `/^TypeError: sandbox must be an object$/`.
PR-URL: https://github.com/nodejs/node/pull/14266
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Diffstat (limited to 'test/parallel/test-vm-create-context-arg.js')
-rw-r--r-- | test/parallel/test-vm-create-context-arg.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/parallel/test-vm-create-context-arg.js b/test/parallel/test-vm-create-context-arg.js index 87695b34ec..8675add90c 100644 --- a/test/parallel/test-vm-create-context-arg.js +++ b/test/parallel/test-vm-create-context-arg.js @@ -26,7 +26,7 @@ const vm = require('vm'); assert.throws(function() { vm.createContext('string is not supported'); -}, TypeError); +}, /^TypeError: sandbox must be an object$/); assert.doesNotThrow(function() { vm.createContext({ a: 1 }); |