Debian Codegraph @

tests/auto/qml/ecmascripttests/test262/test/built-ins/Object/getOwnPropertyNames/15.2.3.4-4-50.js

raw
1 // Copyright (c) 2012 Ecma International. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3
4 /*---
5 es5id: 15.2.3.4-4-50
6 description: >
7 Object.getOwnPropertyNames - non-enumerable own property of 'O' is
8 pushed into the returned Array
9 ---*/
10
11 var obj = {};
12
13 Object.defineProperty(obj, "nonEnumerableProp", {
14 value: 10,
15 enumerable: false,
16 configurable: true
17 });
18
19 var result = Object.getOwnPropertyNames(obj);
20
21 assert.sameValue(result[0], "nonEnumerableProp", 'result[0]');