Skip to content

Commit

Permalink
Test Temporal.Instant w/ trailing zeroes in offset
Browse files Browse the repository at this point in the history
I noticed a small test hole in codecov: we weren't testing
Temporal.Instant parsing with trailing zeroes in the offset.
I also didn't see fractional offset testing, so added that too.
  • Loading branch information
justingrant authored and Ms2ger committed Jul 27, 2023
1 parent 9437cab commit 4257163
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions test/built-ins/Temporal/Instant/from/argument-string.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,33 @@ const tests = [
['+0019761118T152330.1+00:00', 217178610100000000n],
['+0019761118T152330.1+0000', 217178610100000000n],
['1976-11-18T15:23:30+00', 217178610000000000n],
['1976-11-18T15:23:30.123456789-00:00:00', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.0', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.00', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.0000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.00000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.000000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.0000000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.00000000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.000000000', 217178610123456789n],
['1976-11-18T15:23:30.123456789-00:00:00.1', 217178610223456789n],
['1976-11-18T15:23:30.123456789-00:00:00.01', 217178610133456789n],
['1976-11-18T15:23:30.123456789-00:00:00.001', 217178610124456789n],
['1976-11-18T15:23:30.123456789-00:00:00.0001', 217178610123556789n],
['1976-11-18T15:23:30.123456789-00:00:00.00001', 217178610123466789n],
['1976-11-18T15:23:30.123456789-00:00:00.000001', 217178610123457789n],
['1976-11-18T15:23:30.123456789-00:00:00.0000001', 217178610123456889n],
['1976-11-18T15:23:30.123456789-00:00:00.00000001', 217178610123456799n],
['1976-11-18T15:23:30.123456789-00:00:00.000000001', 217178610123456790n],
['1976-11-18T15:23:30.123456789-00:00:00.100000000', 217178610223456789n],
['1976-11-18T15:23:30.123456789-00:00:00.010000000', 217178610133456789n],
['1976-11-18T15:23:30.123456789-00:00:00.001000000', 217178610124456789n],
['1976-11-18T15:23:30.123456789-00:00:00.000100000', 217178610123556789n],
['1976-11-18T15:23:30.123456789-00:00:00.000010000', 217178610123466789n],
['1976-11-18T15:23:30.123456789-00:00:00.000001000', 217178610123457789n],
['1976-11-18T15:23:30.123456789-00:00:00.000000100', 217178610123456889n],
['1976-11-18T15:23:30.123456789-00:00:00.000000010', 217178610123456799n],
['1976-11-18T15Z', 217177200000000000n],
['1976-11-18T15:23:30.123456789Z[u-ca=discord]', 217178610123456789n],
['1976-11-18T15:23:30.123456789Z[+00]', 217178610123456789n],
Expand Down

0 comments on commit 4257163

Please sign in to comment.