[GH-ISSUE #247] A test in the CI fails randomly #84

Closed
opened 2026-02-27 20:23:01 +03:00 by kerem · 2 comments
Owner

Originally created by @marioortizmanero on GitHub (Aug 31, 2021).
Original GitHub issue: https://github.com/ramsayleung/rspotify/issues/247

Describe the bug

There's a test that fails randomly in the CI. It's not consistently reproducible.

See for example:

https://github.com/ramsayleung/rspotify/runs/3474418373

Originally created by @marioortizmanero on GitHub (Aug 31, 2021). Original GitHub issue: https://github.com/ramsayleung/rspotify/issues/247 **Describe the bug** There's a test that fails randomly in the CI. It's not consistently reproducible. See for example: https://github.com/ramsayleung/rspotify/runs/3474418373
kerem 2026-02-27 20:23:01 +03:00
Author
Owner

@marioortizmanero commented on GitHub (Aug 31, 2021):

This command can be used in order to eventually get the error: while cargo test test_read_token_cache; do :; done

<!-- gh-comment-id:909500194 --> @marioortizmanero commented on GitHub (Aug 31, 2021): This command can be used in order to eventually get the error: `while cargo test test_read_token_cache; do :; done`
Author
Owner

@marioortizmanero commented on GitHub (Aug 31, 2021):

Well duh of course that tests fails; I don't even know how it was working in the first place. It was setting Token::expires_at to Utc::now, so when reading token it was already expired and the function returned None.

<!-- gh-comment-id:909502906 --> @marioortizmanero commented on GitHub (Aug 31, 2021): Well duh of course that tests fails; I don't even know how it was working in the first place. It was setting `Token::expires_at` to `Utc::now`, so when reading token it was already expired and the function returned `None`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/rspotify#84
No description provided.