Skip to content

Conversation

@uranusjr
Copy link
Member

@uranusjr uranusjr commented Dec 6, 2023

See discussion #35887 (review)

These tests logically depend on the fact that the test suite is run in UTC. While that is true and expected to remain this way for the foreseeable future, it is better to make them use UTC explicitly.

Note that timetables are expected to return times in UTC anyway.

@uranusjr uranusjr requested a review from dstandish December 6, 2023 08:17
These tests logically depend on the fact that the test suite is run in
UTC. While that is true and expected to remain this way for the
foreseeable future, it is better to make them use UTC explicitly.

Note that timetables are expected to return times in UTC anyway.
Pendulum does not implement caching in the constructor, but with a
wrapper function. This causes issues in tests due to classes such as
Timezone does not implement equality, making asserts difficult.

By using the wrapper functions instead, we can help Pendulum produces
equal values more consistently.
@uranusjr uranusjr force-pushed the use-utc-in-timetable-tests branch from 591f2cd to 8944682 Compare December 7, 2023 09:37
@uranusjr uranusjr merged commit c1d28b3 into apache:main Dec 7, 2023
@uranusjr uranusjr deleted the use-utc-in-timetable-tests branch December 7, 2023 18:36
@ephraimbuddy ephraimbuddy added this to the Airflow 2.8.1 milestone Jan 10, 2024
@ephraimbuddy ephraimbuddy added the changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) label Jan 10, 2024
ephraimbuddy pushed a commit that referenced this pull request Jan 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants