Skip to content

Commit

Permalink
Put calculated values first
Browse files Browse the repository at this point in the history
  • Loading branch information
jessealama committed Feb 4, 2022
1 parent c07feb1 commit cf7a2a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions test/built-ins/Temporal/PlainMonthDay/calendar-always.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ features: [Temporal]
const pmd = new Temporal.PlainMonthDay(10, 31, "iso8601", 2019);

assert.sameValue(
"2019-10-31[u-ca=iso8601]",
pmd.toString({ calendarName: 'always' }),
"2019-10-31[u-ca=iso8601]",
"emit year-month-day if calendarName = 'always' (four-argument constructor)"
);

const anotherPMD = Temporal.PlainMonthDay.from("2019-10-31"); // 2019 will get dropped

assert.sameValue(
"1972-10-31[u-ca=iso8601]",
anotherPMD.toString({ calendarName: 'always' }),
"1972-10-31[u-ca=iso8601]",
"emit fallback year if calendarName = 'always' (static from)"
);
4 changes: 2 additions & 2 deletions test/built-ins/Temporal/PlainYearMonth/calendar-always.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ features: [Temporal]
const pym = new Temporal.PlainYearMonth(2019, 10, "iso8601", 31);

assert.sameValue(
"2019-10-31[u-ca=iso8601]",
pym.toString({ calendarName: 'always' }),
"2019-10-31[u-ca=iso8601]",
"emit year-month-day if calendarName = 'always' (four-argument constructor)"
);

const anotherPYM = Temporal.PlainYearMonth.from("2019-10-31"); // 31 will get dropped

assert.sameValue(
"2019-10-01[u-ca=iso8601]",
anotherPYM.toString({ calendarName: 'always' }),
"2019-10-01[u-ca=iso8601]",
"emit fallback day if calendarName = 'always' (static from)"
);

0 comments on commit cf7a2a4

Please sign in to comment.