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 italoacasas committed Dec 21, 2016
1 parent 2a5f789 commit b73402d
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 b73402d

Please sign in to comment.