From 0cdb76bcf3ab2395815e3fa1fcd53fc9c5ec6620 Mon Sep 17 00:00:00 2001 From: bitfl0wer Date: Mon, 20 Nov 2023 14:11:56 +0100 Subject: [PATCH] remove all .await from wasm tests --- tests/auth.rs | 2 +- tests/channels.rs | 12 ++++++------ tests/gateway.rs | 8 ++++---- tests/guilds.rs | 10 +++++----- tests/instance.rs | 2 +- tests/invites.rs | 2 +- tests/members.rs | 2 +- tests/messages.rs | 8 ++++---- tests/relationships.rs | 8 ++++---- tests/roles.rs | 4 ++-- 10 files changed, 29 insertions(+), 29 deletions(-) diff --git a/tests/auth.rs b/tests/auth.rs index 4c79562..b6731d7 100644 --- a/tests/auth.rs +++ b/tests/auth.rs @@ -24,5 +24,5 @@ async fn test_registration() { #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_registration_wasm() { - test_registration().await + test_registration() } diff --git a/tests/channels.rs b/tests/channels.rs index d1b85b2..270f64f 100644 --- a/tests/channels.rs +++ b/tests/channels.rs @@ -13,32 +13,32 @@ wasm_bindgen_test_configure!(run_in_browser); #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_get_channel_wasm() { - get_channel().await + get_channel() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_delete_channel_wasm() { - delete_channel().await + delete_channel() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_modify_channel_wasm() { - modify_channel().await + modify_channel() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_get_channel_messages_wasm() { - get_channel_messages().await + get_channel_messages() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_create_dm_wasm() { - create_dm().await + create_dm() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_remove_add_person_from_to_dm_wasm() { - remove_add_person_from_to_dm().await + remove_add_person_from_to_dm() } #[tokio::test] diff --git a/tests/gateway.rs b/tests/gateway.rs index a05a798..54de74f 100644 --- a/tests/gateway.rs +++ b/tests/gateway.rs @@ -13,25 +13,25 @@ wasm_bindgen_test_configure!(run_in_browser); #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_gateway_establish_wasm() { - test_gateway_establish().await + test_gateway_establish() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_gateway_authenticate_wasm() { - test_gateway_authenticate().await + test_gateway_authenticate() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_self_updating_structs_wasm() { - test_self_updating_structs().await + test_self_updating_structs() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_recursive_self_updating_structs_wasm() { - test_recursive_self_updating_structs().await + test_recursive_self_updating_structs() } #[tokio::test] diff --git a/tests/guilds.rs b/tests/guilds.rs index 2bafbab..fd684dd 100644 --- a/tests/guilds.rs +++ b/tests/guilds.rs @@ -12,31 +12,31 @@ wasm_bindgen_test_configure!(run_in_browser); #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn guild_creation_deletion_wasm() { - guild_creation_deletion().await + guild_creation_deletion() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn get_channels_wasm() { - get_channels().await + get_channels() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn guild_create_ban_wasm() { - guild_create_ban().await + guild_create_ban() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn modify_guild_wasm() { - modify_guild().await + modify_guild() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn guild_remove_member_wasm() { - guild_remove_member().await + guild_remove_member() } #[tokio::test] diff --git a/tests/instance.rs b/tests/instance.rs index 2466e60..1ffe914 100644 --- a/tests/instance.rs +++ b/tests/instance.rs @@ -8,7 +8,7 @@ wasm_bindgen_test_configure!(run_in_browser); #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn guild_creation_deletion_wasm() { - guild_creation_deletion().await + guild_creation_deletion() } #[tokio::test] diff --git a/tests/invites.rs b/tests/invites.rs index a535b84..031afeb 100644 --- a/tests/invites.rs +++ b/tests/invites.rs @@ -9,7 +9,7 @@ wasm_bindgen_test_configure!(run_in_browser); #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn create_accept_invite_wasm() { - create_accept_invite().await + create_accept_invite() } #[tokio::test] diff --git a/tests/members.rs b/tests/members.rs index a2043ef..0dd3616 100644 --- a/tests/members.rs +++ b/tests/members.rs @@ -10,7 +10,7 @@ mod common; #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn add_remove_role_wasm() { - add_remove_role().await.unwrap() + add_remove_role().unwrap() } #[tokio::test] diff --git a/tests/messages.rs b/tests/messages.rs index fc46831..a39e9a0 100644 --- a/tests/messages.rs +++ b/tests/messages.rs @@ -13,25 +13,25 @@ mod common; #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn send_message_wasm() { - send_message().await + send_message() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn send_message_attachment_wasm() { - send_message_attachment().await + send_message_attachment() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn search_messages_wasm() { - search_messages().await + search_messages() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_stickies_wasm() { - test_stickies().await + test_stickies() } #[tokio::test] diff --git a/tests/relationships.rs b/tests/relationships.rs index 7f26e0f..112b47e 100644 --- a/tests/relationships.rs +++ b/tests/relationships.rs @@ -10,25 +10,25 @@ mod common; #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_get_relationships_wasm() { - test_get_relationships().await + test_get_relationships() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_get_mutual_relationships_wasm() { - test_get_mutual_relationships().await + test_get_mutual_relationships() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_modify_relationship_friends_wasm() { - test_modify_relationship_friends().await + test_modify_relationship_friends() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn test_modify_relationship_block_wasm() { - test_modify_relationship_block().await + test_modify_relationship_block() } #[tokio::test] diff --git a/tests/roles.rs b/tests/roles.rs index 0dd3b7f..5e85fbc 100644 --- a/tests/roles.rs +++ b/tests/roles.rs @@ -10,13 +10,13 @@ mod common; #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn create_and_get_roles_wasm() { - create_and_get_roles().await + create_and_get_roles() } #[cfg(target_arch = "wasm32")] #[wasm_bindgen_test] async fn get_and_delete_role_wasm() { - get_and_delete_role().await + get_and_delete_role() } #[tokio::test]