name.js (1076B)
1 // |reftest| skip-if(!this.hasOwnProperty('Temporal')) -- Temporal is not enabled unconditionally 2 // Copyright (C) 2021 the V8 project authors. All rights reserved. 3 // This code is governed by the BSD license found in the LICENSE file. 4 5 /*--- 6 esid: sec-temporal.now.timezoneid 7 description: Temporal.Now.timeZoneId.name is "timeZoneId". 8 info: | 9 ## 17 ECMAScript Standard Built-in Objects: 10 Every built-in Function object, including constructors, that is not 11 identified as an anonymous function has a name property whose value is a 12 String. 13 14 Unless otherwise specified, the name property of a built-in Function object, 15 if it exists, has the attributes { [[Writable]]: false, [[Enumerable]]: 16 false, [[Configurable]]: true }. 17 includes: [propertyHelper.js] 18 features: [Temporal] 19 ---*/ 20 21 assert.sameValue( 22 Temporal.Now.timeZoneId.name, 23 'timeZoneId', 24 'The value of Temporal.Now.timeZoneId.name is expected to be "timeZoneId"' 25 ); 26 27 verifyProperty(Temporal.Now.timeZoneId, 'name', { 28 enumerable: false, 29 writable: false, 30 configurable: true 31 }); 32 33 reportCompare(0, 0);