Skip to content

Commit

Permalink
add debug to controller test on failure
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyandrews committed Dec 6, 2022
1 parent 1754a68 commit 886fda7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/controller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -781,7 +781,10 @@ async fn update_state(test_state: Option<TestState>, test_type: &TestType) -> Te
async fn make_request(test_state: &mut TestState, command: &str) {
//println!("making request: {}", command);
if let Some(stream) = test_state.telnet_stream.as_mut() {
stream.write_all(command.as_bytes()).await.unwrap()
match stream.write_all(command.as_bytes()).await {
Ok(_) => (),
Err(e) => panic!("failed to send {} command: {}", command, e),
};
} else if let Some(ws_sender) = test_state.websocket_sender.as_mut() {
ws_sender
.send(Message::Text(
Expand Down

0 comments on commit 886fda7

Please sign in to comment.