File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -74,6 +74,8 @@ impl<'r> AdminRequest<'r> {
7474
7575#[ derive( Debug ) ]
7676struct InvalidVisit ;
77+
78+ #[ cfg_attr( test, derive( Debug ) ) ]
7779struct Visit {
7880 proposal : u32 ,
7981 session : u16 ,
@@ -179,6 +181,7 @@ impl From<reqwest::Error> for AuthError {
179181mod tests {
180182 use std:: str:: FromStr as _;
181183
184+ use assert_matches:: assert_matches;
182185 use axum:: http:: HeaderValue ;
183186 use axum_extra:: headers:: authorization:: { Bearer , Credentials } ;
184187 use axum_extra:: headers:: Authorization ;
@@ -211,7 +214,7 @@ mod tests {
211214 #[ case:: invalid_proposal( "cm123abc-12" ) ]
212215 #[ case:: negative_session( "cm1234--12" ) ]
213216 fn invalid_visit ( #[ case] visit : & str ) {
214- assert ! ( matches! ( Visit :: from_str( visit) , Err ( InvalidVisit ) ) )
217+ assert_matches ! ( Visit :: from_str( visit) , Err ( InvalidVisit ) )
215218 }
216219
217220 #[ tokio:: test]
You can’t perform that action at this time.
0 commit comments