@@ -952,22 +952,22 @@ mod tests {
952952 }
953953 } ;
954954 let info_msg = format ! ( "run_lex input: {}\n expected: {:?}\n received: {:?}" , input, expected_tokens, tokens) ;
955- assert ! ( tokens == expected_tokens, "{}" , info_msg ) ;
955+ assert ! ( tokens == expected_tokens, "{info_msg}" ) ;
956956
957957 // Prove we can handle multiple spaces wherever we handle a single space
958958 let input_extra_spaces = input. replace ( " " , " " ) ;
959959 let tokens_extra_spaces = lex ( & input_extra_spaces, false , Unit :: Celsius ) . unwrap ( ) ;
960- assert ! ( tokens_extra_spaces == expected_tokens, "{}" , info_msg ) ;
960+ assert ! ( tokens_extra_spaces == expected_tokens, "{info_msg}" ) ;
961961
962962 // Prove we don't need spaces around operators
963963 let input_stripped_spaces = strip_operator_spacing. replace_all ( input, "$1" ) ;
964964 let tokens_stripped_spaces = lex ( & input_stripped_spaces, false , Unit :: Celsius ) . unwrap ( ) ;
965- assert ! ( tokens_stripped_spaces == expected_tokens, "{}" , info_msg ) ;
965+ assert ! ( tokens_stripped_spaces == expected_tokens, "{info_msg}" ) ;
966966
967967 // Prove we don't need a space after a digit
968968 let input_afterdigit_stripped_spaces = strip_afterdigit_spacing. replace_all ( input, "$1" ) ;
969969 let tokens_afterdigit_stripped_spaces = lex ( & input_afterdigit_stripped_spaces, false , Unit :: Celsius ) . unwrap ( ) ;
970- assert ! ( tokens_afterdigit_stripped_spaces == expected_tokens, "{}" , info_msg ) ;
970+ assert ! ( tokens_afterdigit_stripped_spaces == expected_tokens, "{info_msg}" ) ;
971971 } ;
972972
973973 let run_datarate_lex = |input : & str , expected_tokens : Vec < Token > | {
@@ -977,7 +977,7 @@ mod tests {
977977 let input_nonplural_units = nonplural_data_units. replace_all ( input, "$1" ) ;
978978 let tokens_nonplural_units = lex ( & input_nonplural_units, false , Unit :: Celsius ) . unwrap ( ) ;
979979 let info_msg = format ! ( "run_datarate_lex input: {}\n expected: {:?}\n received: {:?}" , input, expected_tokens, tokens_nonplural_units) ;
980- assert ! ( tokens_nonplural_units == expected_tokens, "{}" , info_msg ) ;
980+ assert ! ( tokens_nonplural_units == expected_tokens, "{info_msg}" ) ;
981981 } ;
982982
983983 run_lex ( "88 kilometres * 2" , vec ! [ numtok!( 88 ) , Token :: Unit ( Kilometer ) , Token :: Operator ( Multiply ) , numtok!( 2 ) ] ) ;
0 commit comments