From 6a0333e812574be4462ca03df4c80cb1c3e7ee62 Mon Sep 17 00:00:00 2001 From: Benjamin Bouvier Date: Thu, 16 Jan 2025 10:54:19 +0100 Subject: [PATCH] test: replace Option::default() by None --- crates/matrix-sdk/tests/integration/room/tags.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/matrix-sdk/tests/integration/room/tags.rs b/crates/matrix-sdk/tests/integration/room/tags.rs index dc48244d3da..9d17a0cc555 100644 --- a/crates/matrix-sdk/tests/integration/room/tags.rs +++ b/crates/matrix-sdk/tests/integration/room/tags.rs @@ -92,7 +92,7 @@ async fn test_set_favourite() { // Server will be called to set the room as favourite. mock_tag_api(&server, TagName::Favorite, TagOperation::Set, 1).await; - room.set_is_favourite(true, Option::default()).await.unwrap(); + room.set_is_favourite(true, None).await.unwrap(); // Mock the response from the server. let tags = BTreeMap::from([(TagName::Favorite, TagInfo::default())]); @@ -125,7 +125,7 @@ async fn test_set_favourite_on_low_priority_room() { mock_tag_api(&server, TagName::Favorite, TagOperation::Set, 1).await; mock_tag_api(&server, TagName::LowPriority, TagOperation::Remove, 1).await; - room.set_is_favourite(true, Option::default()).await.unwrap(); + room.set_is_favourite(true, None).await.unwrap(); // Mock the response from the server. let tags = BTreeMap::from([(TagName::Favorite, TagInfo::default())]); @@ -148,7 +148,7 @@ async fn test_unset_favourite() { // Server will be called to unset the room as favourite. mock_tag_api(&server, TagName::Favorite, TagOperation::Remove, 1).await; - room.set_is_favourite(false, Option::default()).await.unwrap(); + room.set_is_favourite(false, None).await.unwrap(); server.verify().await; } @@ -165,7 +165,7 @@ async fn test_set_low_priority() { // Server will be called to set the room as favourite. mock_tag_api(&server, TagName::LowPriority, TagOperation::Set, 1).await; - room.set_is_low_priority(true, Option::default()).await.unwrap(); + room.set_is_low_priority(true, None).await.unwrap(); // Mock the response from the server. let tags = BTreeMap::from([(TagName::LowPriority, TagInfo::default())]); @@ -198,7 +198,7 @@ async fn test_set_low_priority_on_favourite_room() { mock_tag_api(&server, TagName::LowPriority, TagOperation::Set, 1).await; mock_tag_api(&server, TagName::Favorite, TagOperation::Remove, 1).await; - room.set_is_low_priority(true, Option::default()).await.unwrap(); + room.set_is_low_priority(true, None).await.unwrap(); // Mock the response from the server. let tags = BTreeMap::from([(TagName::LowPriority, TagInfo::default())]); @@ -221,7 +221,7 @@ async fn test_unset_low_priority() { // Server will be called to unset the room as favourite. mock_tag_api(&server, TagName::LowPriority, TagOperation::Remove, 1).await; - room.set_is_low_priority(false, Option::default()).await.unwrap(); + room.set_is_low_priority(false, None).await.unwrap(); server.verify().await; }