From adcefa220b3c2fe923f612c70f9bfbca4e0c478d Mon Sep 17 00:00:00 2001 From: Jonas Platte Date: Wed, 31 Jul 2024 14:02:34 +0200 Subject: [PATCH] server: Fix new compiler / clippy warnings --- server/svix-server/src/core/cache/memory.rs | 2 -- server/svix-server/src/core/cache/redis.rs | 4 +--- server/svix-server/tests/it/redis_queue.rs | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/server/svix-server/src/core/cache/memory.rs b/server/svix-server/src/core/cache/memory.rs index ed399e239..390bb8acf 100644 --- a/server/svix-server/src/core/cache/memory.rs +++ b/server/svix-server/src/core/cache/memory.rs @@ -132,8 +132,6 @@ mod tests { } } - #[derive(Deserialize, Serialize, Debug, PartialEq)] - struct StringTestVal(String); string_kv_def!(StringTestKey); impl StringTestKey { fn new(id: String) -> StringTestKey { diff --git a/server/svix-server/src/core/cache/redis.rs b/server/svix-server/src/core/cache/redis.rs index 19261c192..ceaa7ffa4 100644 --- a/server/svix-server/src/core/cache/redis.rs +++ b/server/svix-server/src/core/cache/redis.rs @@ -67,7 +67,7 @@ impl CacheBehavior for RedisCache { async fn delete(&self, key: &T) -> Result<()> { let mut pool = self.redis.get().await?; - pool.del(key.as_ref()).await?; + let _: () = pool.del(key.as_ref()).await?; Ok(()) } @@ -103,8 +103,6 @@ mod tests { } } - #[derive(Deserialize, Serialize, Debug, PartialEq)] - struct StringTestVal(String); string_kv_def!(StringTestKey); impl StringTestKey { fn new(id: String) -> StringTestKey { diff --git a/server/svix-server/tests/it/redis_queue.rs b/server/svix-server/tests/it/redis_queue.rs index 084a97277..22c9bf70a 100644 --- a/server/svix-server/tests/it/redis_queue.rs +++ b/server/svix-server/tests/it/redis_queue.rs @@ -39,7 +39,7 @@ async fn test_many_queue_consumers_inner(prefix: &str, delay: Option) let mut conn = pool.get().await.unwrap(); let _: () = conn - .del(&format!("{prefix}{{queue}}_svix_v3_main")) + .del(format!("{prefix}{{queue}}_svix_v3_main")) .await .unwrap(); }