diff --git a/test/known_issues/test-vm-inherited_properties.js b/test/known_issues/test-vm-inherited_properties.js new file mode 100644 index 0000000000..f90cf3568e --- /dev/null +++ b/test/known_issues/test-vm-inherited_properties.js @@ -0,0 +1,20 @@ +'use strict'; +// Ref: https://github.com/nodejs/node/issues/5350 + +require('../common'); +const vm = require('vm'); +const assert = require('assert'); + +const base = { + propBase: 1 +}; + +const sandbox = Object.create(base, { + propSandbox: {value: 3} +}); + +const context = vm.createContext(sandbox); + +const result = vm.runInContext('this.hasOwnProperty("propBase");', context); + +assert.strictEqual(result, false);