Skip to content

Commit eff3a48

Browse files
AnnaMagevanlucas
authored andcommitted
test: add known_issues test for #10223
PR-URL: #11024 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]>
1 parent 72a97b6 commit eff3a48

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
'use strict';
2+
// Refs: https://github.com/nodejs/node/issues/10223
3+
4+
require('../common');
5+
const vm = require('vm');
6+
const assert = require('assert');
7+
8+
const context = vm.createContext({});
9+
10+
const code = `
11+
Object.defineProperty(this, 'foo', {value: 5});
12+
Object.getOwnPropertyDescriptor(this, 'foo');
13+
`;
14+
15+
const desc = vm.runInContext(code, context);
16+
17+
assert.strictEqual(desc.writable, false);

0 commit comments

Comments
 (0)