mirror of
https://github.com/chatmail/core.git
synced 2026-04-22 16:06:30 +03:00
feat: Log failed debug assertions in all configurations
Add `logged_debug_assert` macro logging a warning if a condition is not satisfied, before invoking
`debug_assert!`, and use this macro where `Context` is accessible (i.e. don't change function
signatures for now).
Follow-up to 0359481ba4.
This commit is contained in:
@@ -754,7 +754,7 @@ impl TestContext {
|
||||
pub async fn add_or_lookup_address_contact(&self, other: &TestContext) -> Contact {
|
||||
let contact_id = self.add_or_lookup_address_contact_id(other).await;
|
||||
let contact = Contact::get_by_id(&self.ctx, contact_id).await.unwrap();
|
||||
debug_assert_eq!(contact.is_key_contact(), false);
|
||||
assert_eq!(contact.is_key_contact(), false);
|
||||
contact
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user