Skip to content

Commit

Permalink
Address clippy reported issues
Browse files Browse the repository at this point in the history
A recent version of clippy complains about a redundant guard in two of
our tests. Fix these occurrences as per its suggestion.
  • Loading branch information
d-e-s-o committed Nov 9, 2023
1 parent 2f518f8 commit 369e187
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/api/v2/updates.rs
Original file line number Diff line number Diff line change
Expand Up @@ -568,8 +568,9 @@ mod tests {
let result = mock_stream::<OrderUpdates, _, _>(test).await;
match result {
Ok(..) => panic!("authentication succeeded unexpectedly"),
Err(Error::WebSocket(WebSocketError::Protocol(e)))
if e == ProtocolError::ResetWithoutClosingHandshake => {},
Err(Error::WebSocket(WebSocketError::Protocol(
ProtocolError::ResetWithoutClosingHandshake,
))) => {},
Err(e) => panic!("received unexpected error: {e}"),
}
}
Expand Down Expand Up @@ -627,8 +628,7 @@ mod tests {

let err = mock_stream::<OrderUpdates, _, _>(test).await.unwrap_err();
match err {
Error::WebSocket(WebSocketError::Protocol(e))
if e == ProtocolError::ResetWithoutClosingHandshake => {},
Error::WebSocket(WebSocketError::Protocol(ProtocolError::ResetWithoutClosingHandshake)) => {},
e => panic!("received unexpected error: {e}"),
}
}
Expand Down

0 comments on commit 369e187

Please sign in to comment.