Debian Codegraph @

js/src/tests/test262/built-ins/Temporal/Now/plainDateTimeISO/time-zone-undefined.js

raw
1 // |reftest| shell-option(--enable-temporal) skip-if(!this.hasOwnProperty('Temporal')||!xulRuntime.shell) -- Temporal is not enabled unconditionally, requires shell-options
2 // Copyright (C) 2021 Igalia, S.L. All rights reserved.
3 // This code is governed by the BSD license found in the LICENSE file.
4
5 /*---
6 esid: sec-temporal.now.plaindatetimeiso
7 description: Functions when time zone argument is omitted
8 features: [Temporal]
9 ---*/
10
11 const resultExplicit = Temporal.Now.plainDateTimeISO(undefined);
12 assert(
13 resultExplicit instanceof Temporal.PlainDateTime,
14 'The result of evaluating (resultExplicit instanceof Temporal.PlainDateTime) is expected to be true'
15 );
16
17 const resultImplicit = Temporal.Now.plainDateTimeISO();
18 assert(
19 resultImplicit instanceof Temporal.PlainDateTime,
20 'The result of evaluating (resultImplicit instanceof Temporal.PlainDateTime) is expected to be true'
21 );
22
23 reportCompare(0, 0);