test: timing test waits longer than expiry
All checks were successful
Rust / build (push) Successful in 1m52s
ci/woodpecker/push/cron-docker-builder Pipeline was successful
ci/woodpecker/push/push-next Pipeline was successful
ci/woodpecker/push/tag-created Pipeline was successful

This commit is contained in:
Paul Campbell 2024-08-04 10:03:40 +01:00
parent b1d5344cfa
commit 5d64692f31

View file

@ -35,6 +35,8 @@ fn when_history_has_expired_then_message_is_passed() {
let result = history.sendable(user_notification);
let_assert!(Some(user_notification) = result);
std::thread::sleep(dur);
// twice the expiry duration to avoid things happening in the wrong order
std::thread::sleep(dur);
// after dur, message has expired, so is still valid