summaryrefslogtreecommitdiffstats
path: root/js/src/tests/test262/built-ins/Temporal/PlainDate/prototype/toPlainDateTime/custom.js
blob: feecd145abda5bd01b55ed41582e50cf2f66f4ca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// |reftest| skip-if(!this.hasOwnProperty('Temporal')) -- Temporal is not enabled unconditionally
// Copyright (C) 2022 Igalia, S.L. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.

/*---
esid: sec-temporal.plaindate.prototype.toplaindatetime
description: toPlainDateTime() doesn't call into the calendar.
includes: [temporalHelpers.js]
features: [Temporal]
---*/

const calendar = TemporalHelpers.calendarThrowEverything();
const plainDate = new Temporal.PlainDate(2000, 5, 2, calendar);
const result = plainDate.toPlainDateTime("11:30:23");
assert.sameValue(result.getCalendar(), calendar, "calendar");

reportCompare(0, 0);