From 93bda5f1dc7b3f6618f1eecbd62cff3c4790e5c3 Mon Sep 17 00:00:00 2001 From: Mingun Date: Mon, 7 Aug 2023 21:35:02 +0500 Subject: [PATCH] Rename unit struct to a generic name: Info->Unit --- test_suite/tests/test_enum_internally_tagged.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test_suite/tests/test_enum_internally_tagged.rs b/test_suite/tests/test_enum_internally_tagged.rs index 646b1454..cdf0d4e5 100644 --- a/test_suite/tests/test_enum_internally_tagged.rs +++ b/test_suite/tests/test_enum_internally_tagged.rs @@ -636,16 +636,16 @@ fn newtype_variant_containing_externally_tagged_enum() { #[test] fn newtype_variant_containing_unit_struct() { #[derive(Debug, PartialEq, Serialize, Deserialize)] - struct Info; + struct Unit; #[derive(Debug, PartialEq, Serialize, Deserialize)] #[serde(tag = "tag")] enum Message { - Info(Info), + Info(Unit), } assert_tokens( - &Message::Info(Info), + &Message::Info(Unit), &[ Token::Map { len: Some(1) }, Token::Str("tag"), @@ -655,7 +655,7 @@ fn newtype_variant_containing_unit_struct() { ); assert_de_tokens( - &Message::Info(Info), + &Message::Info(Unit), &[ Token::Struct { name: "Message", @@ -668,7 +668,7 @@ fn newtype_variant_containing_unit_struct() { ); assert_de_tokens( - &Message::Info(Info), + &Message::Info(Unit), &[ Token::Seq { len: Some(1) }, Token::Str("Info"),