Skip to content

Commit

Permalink
test: add known_issues test for #5350
Browse files Browse the repository at this point in the history
PR-URL: #10319
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
  • Loading branch information
AnnaMag authored and evanlucas committed Jan 4, 2017
1 parent 37563fa commit 9a9e530
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions test/known_issues/test-vm-inherited_properties.js
Original file line number Diff line number Diff line change
@@ -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);

0 comments on commit 9a9e530

Please sign in to comment.