From 7cac05a2432946a9bf595b8eec2d9acb5c3fd8e9 Mon Sep 17 00:00:00 2001 From: binarybaron Date: Thu, 25 Jul 2024 20:35:23 +0200 Subject: [PATCH] fix: tests --- swap/tests/rpc.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/swap/tests/rpc.rs b/swap/tests/rpc.rs index 28d74c72..c28c0331 100644 --- a/swap/tests/rpc.rs +++ b/swap/tests/rpc.rs @@ -79,7 +79,7 @@ mod test { } // Helper function for HashMap - fn assert_has_keys_hashmap(map: &serde_json::Map, keys: &[&str]) { + fn assert_has_keys_hashmap(map: &HashMap, keys: &[&str]) { for &key in keys { assert!(map.contains_key(key), "Key {} is missing", key); } @@ -110,7 +110,8 @@ mod test { let swaps = response.get("swaps").unwrap(); assert_eq!(swaps.len(), 1); - assert_has_keys_hashmap( + + assert_has_keys_serde( swaps[0].as_object().unwrap(), &[ "swapId",