Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Let
time::parse::relative::various
fail more often
This tests four inputs representing relative times, instead of one, in order to: 1. Reveal GitoxideLabs#1696 during more of the year when the tests are run on machines set to local time in time zones whose rules include daylight savings clock adjustments. 2. Illuminate the nature and limited extent of GitoxideLabs#1696 by trying both "weeks ago" and "minutes ago" input. (It looks like the "minutes ago" input always passes the test, while the "weeks ago" input can fail the test if the interval includes a DST adjustment.) 3. Cover a wider range of inputs more generally, which is probably a good idea even where GitoxideLabs#1696 is not involved. Although these change intend to, and appear to succeed at, triggering more failures due to that but on affected systems set to local time, they are not expected to produce any new failures on CI, since all platforms' GitHub-hosted GHA runners are set to use UTC. With these changes, the failure, when it occurs, looks like: --- STDERR: gix-date::date time::parse::relative::various --- thread 'time::parse::relative::various' panicked at gix-date\tests\time\parse.rs:209:9: assertion `left == right` failed: relative times differ left: [2024-11-08T21:10:19Z, 2024-11-08T21:10:19Z, 2024-07-05T21:10:19Z, 2024-07-05T21:10:19Z] right: [2024-11-08T21:10:19Z, 2024-11-08T21:10:19Z, 2024-07-05T20:10:19Z, 2024-07-05T21:10:19Z]
- Loading branch information