mirror of
https://github.com/chatmail/core.git
synced 2026-09-22 13:01:21 +03:00
test: remove timeout from pop_sent_msg_ex()
Arbitrary timeouts often result in flaky tests, especially if CI runners may be paused. In this case however timeout was not used by any tests and only slowed down the tests in cases where no message is expected but non-zero timeout is set.
This commit is contained in:
@@ -2030,12 +2030,12 @@ async fn test_no_smtp_job_for_self_chat() -> Result<()> {
|
||||
let chat_id = bob.get_self_chat().await.id;
|
||||
let mut msg = Message::new_text("Happy birthday to me".to_string());
|
||||
chat::send_msg(bob, chat_id, &mut msg).await?;
|
||||
assert!(bob.pop_sent_msg_opt(Duration::ZERO).await.is_none());
|
||||
assert!(bob.pop_sent_msg_opt().await.is_none());
|
||||
|
||||
bob.set_config_bool(Config::BccSelf, true).await?;
|
||||
let mut msg = Message::new_text("Happy birthday to me".to_string());
|
||||
chat::send_msg(bob, chat_id, &mut msg).await?;
|
||||
assert!(bob.pop_sent_msg_opt(Duration::ZERO).await.is_some());
|
||||
assert!(bob.pop_sent_msg_opt().await.is_some());
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user