@@ -71,7 +71,7 @@ fn read_usage_auto_pong_flush() {
7171
7272 // Receiving a ping should auto scheduled a pong on next read or write (but not written yet).
7373 let msg = ws. read ( ) . unwrap ( ) ;
74- assert ! ( matches!( msg, Message :: Ping ( _) ) , "Unexpected msg {:?}" , msg ) ;
74+ assert ! ( matches!( msg, Message :: Ping ( _) ) , "Unexpected msg {msg :?}" ) ;
7575 assert_eq ! ( ws. get_ref( ) . read_calls, 1 ) ;
7676 assert ! ( ws. get_ref( ) . written_data. is_empty( ) , "Unexpected {:?}" , ws. get_ref( ) ) ;
7777 assert ! ( ws. get_ref( ) . flushed_data. is_empty( ) , "Unexpected {:?}" , ws. get_ref( ) ) ;
@@ -81,8 +81,7 @@ fn read_usage_auto_pong_flush() {
8181 let next = ws. read ( ) . unwrap_err ( ) ;
8282 assert ! (
8383 matches!( next, tungstenite:: Error :: Io ( ref err) if err. kind( ) == io:: ErrorKind :: WouldBlock ) ,
84- "Unexpected read err {:?}" ,
85- next
84+ "Unexpected read err {next:?}" ,
8685 ) ;
8786 assert_eq ! ( ws. get_ref( ) . read_calls, 2 ) ;
8887 assert ! ( !ws. get_ref( ) . written_data. is_empty( ) , "Should have written a pong frame" ) ;
@@ -101,8 +100,7 @@ fn read_usage_auto_pong_flush() {
101100 let next = ws. read ( ) . unwrap_err ( ) ;
102101 assert ! (
103102 matches!( next, tungstenite:: Error :: Io ( ref err) if err. kind( ) == io:: ErrorKind :: WouldBlock ) ,
104- "Unexpected read err {:?}" ,
105- next
103+ "Unexpected read err {next:?}" ,
106104 ) ;
107105 assert_eq ! ( ws. get_ref( ) . read_calls, 3 ) ;
108106 assert_eq ! ( ws. get_ref( ) . write_calls, 1 ) ;
@@ -114,8 +112,7 @@ fn read_usage_auto_pong_flush() {
114112 let next = ws. read ( ) . unwrap_err ( ) ;
115113 assert ! (
116114 matches!( next, tungstenite:: Error :: Io ( ref err) if err. kind( ) == io:: ErrorKind :: WouldBlock ) ,
117- "Unexpected read err {:?}" ,
118- next
115+ "Unexpected read err {next:?}" ,
119116 ) ;
120117 assert_eq ! ( ws. get_ref( ) . read_calls, 4 ) ;
121118 assert_eq ! ( ws. get_ref( ) . write_calls, 1 ) ;
0 commit comments