aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--macros/src/declare_interface_args.rs20
1 files changed, 11 insertions, 9 deletions
diff --git a/macros/src/declare_interface_args.rs b/macros/src/declare_interface_args.rs
index c924dca..cf0dbce 100644
--- a/macros/src/declare_interface_args.rs
+++ b/macros/src/declare_interface_args.rs
@@ -154,24 +154,26 @@ mod tests
Foobar -> IFoobar, xyz = false, async = true
};
- assert!(matches!(parse2::<DeclareInterfaceArgs>(input_args), Err(_)));
+ assert!(parse2::<DeclareInterfaceArgs>(input_args).is_err());
}
#[test]
fn cannot_parse_with_duplicate_flag()
{
- assert!(matches!(
+ assert!(
+ // Formatting is weird without this comment
parse2::<DeclareInterfaceArgs>(quote! {
Foobar -> IFoobar, async = true, async = true
- }),
- Err(_)
- ));
+ })
+ .is_err()
+ );
- assert!(matches!(
+ assert!(
+ // Formatting is weird without this comment
parse2::<DeclareInterfaceArgs>(quote! {
Foobar -> IFoobar, async = true, async = false
- }),
- Err(_)
- ));
+ })
+ .is_err()
+ );
}
}