Skip to content

Fix timezone-unstable day-aggregator tests#322

Merged
iamtoruk merged 1 commit into
mainfrom
fix/timezone-stable-tests
May 12, 2026
Merged

Fix timezone-unstable day-aggregator tests#322
iamtoruk merged 1 commit into
mainfrom
fix/timezone-stable-tests

Conversation

@iamtoruk
Copy link
Copy Markdown
Member

Summary

  • Drop Z suffix from test timestamps in tests/day-aggregator.test.ts so date bucketing tests pass in all timezones
  • Timestamps with Z are UTC, which shifts dates in non-UTC zones (e.g. Apr 9 10:00Z becomes Apr 8 22:00 in UTC-12)
  • Local timestamps without Z match how the aggregator actually interprets dates
  • Verified passing in UTC+12, UTC-14, and default timezone

Based on #112 by @lfl1337, extended to cover all affected timestamps (the original PR only fixed 2 of 17).

Timestamps with Z are interpreted as UTC, causing date bucketing tests
to fail in non-UTC timezones (e.g. UTC+12 shifts Apr 9 10:00Z to Apr 8).
Local timestamps without Z are interpreted in the runtime timezone,
matching how the aggregator actually buckets dates.

Based on #112 by @lfl1337, extended to cover all affected timestamps.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant