mirror of
https://github.com/chatmail/core.git
synced 2026-05-08 09:26:29 +03:00
Fix test to use ended_timestamp instead of timestamp_sent
Co-authored-by: link2xt <18373967+link2xt@users.noreply.github.com>
This commit is contained in:
@@ -714,13 +714,13 @@ async fn test_housekeeping_deletes_old_call_sdps() -> Result<()> {
|
|||||||
.await?;
|
.await?;
|
||||||
assert_eq!(sdp_after_end, Some(PLACE_INFO.to_string()));
|
assert_eq!(sdp_after_end, Some(PLACE_INFO.to_string()));
|
||||||
|
|
||||||
// Simulate passage of time by modifying the message timestamp
|
// Simulate passage of time by modifying the ended_timestamp in calls table
|
||||||
// to be older than 24 hours
|
// to be older than 24 hours
|
||||||
let old_timestamp = crate::tools::time() - 86400 - 1; // 24 hours + 1 second ago
|
let old_timestamp = crate::tools::time() - 86400 - 1; // 24 hours + 1 second ago
|
||||||
alice
|
alice
|
||||||
.sql
|
.sql
|
||||||
.execute(
|
.execute(
|
||||||
"UPDATE msgs SET timestamp_sent=? WHERE id=?",
|
"UPDATE calls SET ended_timestamp=? WHERE msg_id=?",
|
||||||
(old_timestamp, call_id),
|
(old_timestamp, call_id),
|
||||||
)
|
)
|
||||||
.await?;
|
.await?;
|
||||||
|
|||||||
Reference in New Issue
Block a user