Skip to content

Commit

Permalink
Fix date offset in overload test
Browse files Browse the repository at this point in the history
  • Loading branch information
jasongin committed Sep 14, 2024
1 parent 5e77f2b commit f87d51f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/TestCases/napi-dotnet/overloads.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,9 @@ Overloads.collectionMethod4(testAsyncIterable).then(
const dateWithKind = new Date(Date.UTC(2024, 1, 29));
dateWithKind.kind = 'utc';
assert.strictEqual(Overloads.dateTimeMethod(dateWithKind), '2024-02-29T00:00:00: DateTime');
const dateWithOffset = new Date(2024, 1, 29);
const dateWithOffset = new Date(Date.UTC(2024, 1, 29));
dateWithOffset.offset = -10 * 60;
assert.strictEqual(Overloads.dateTimeMethod(dateWithOffset), '2024-02-29T00:00:00: DateTimeOffset');
assert.strictEqual(Overloads.dateTimeMethod(dateWithOffset), '2024-02-28T14:00:00: DateTimeOffset');
assert.strictEqual(Overloads.dateTimeMethod(11 * 60 * 1000), '00:11:00: TimeSpan');

assert.strictEqual(Overloads.otherMethod(TestEnum.One), 'One: TestEnum');
Expand Down

0 comments on commit f87d51f

Please sign in to comment.