test262/src/dynamic-import/ns-get-own-property-sym.case
2018-10-12 17:27:00 -04:00

32 lines
1.1 KiB
Plaintext

// Copyright (C) 2018 Leo Balter. All rights reserved.
// Copyright (C) 2016 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
esid: sec-module-namespace-exotic-objects-getownproperty-p
desc: >
Behavior of the [[GetOwnProperty]] internal method with a Symbol argument
features: [Symbol, Symbol.toStringTag]
template: namespace
---*/
//- setup
var notFound = Symbol('test262');
//- import
import('./module-code_FIXTURE.js')
//- body
var desc;
assert.sameValue(
Object.prototype.hasOwnProperty.call(ns, Symbol.toStringTag), true
);
desc = Object.getOwnPropertyDescriptor(ns, Symbol.toStringTag);
assert.sameValue(desc.value, ns[Symbol.toStringTag]);
assert.sameValue(desc.enumerable, false, 'Symbol.toStringTag enumerable');
assert.sameValue(desc.writable, false, 'Symbol.toStringTag writable');
assert.sameValue(desc.configurable, false, 'Symbol.toStringTag configurable');
assert.sameValue(Object.prototype.hasOwnProperty.call(ns, notFound), false);
desc = Object.getOwnPropertyDescriptor(ns, notFound);
assert.sameValue(desc, undefined);