mirror of
https://github.com/nodejs/node.git
synced 2025-05-06 23:10:15 +00:00

PR-URL: https://github.com/nodejs/node/pull/10550 Reviewed-By: Rich Trott <rtrott@gmail.com>
16 lines
302 B
JavaScript
16 lines
302 B
JavaScript
'use strict';
|
|
require('../common');
|
|
const vm = require('vm');
|
|
|
|
console.error('beginning');
|
|
|
|
try {
|
|
vm.runInThisContext('var 4;', { filename: 'foo.vm', displayErrors: true });
|
|
} catch (err) {
|
|
console.error(err.stack);
|
|
}
|
|
|
|
vm.runInThisContext('var 5;', { filename: 'test.vm' });
|
|
|
|
console.error('end');
|