Skip to content

Commit

Permalink
Try to deflake tests in GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
ekzhang committed Jun 11, 2024
1 parent 2a98438 commit 72f8294
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/e2e_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ lazy_static! {
/// Spawn the server, giving some time for the control port TcpListener to start.
async fn spawn_server(secret: Option<&str>) {
tokio::spawn(Server::new(1024..=65535, secret).listen());
time::sleep(Duration::from_millis(50)).await;
time::sleep(Duration::from_millis(100)).await;
}

/// Spawns a client with randomly assigned ports, returning the listener and remote address.
Expand Down Expand Up @@ -68,6 +68,7 @@ async fn basic_proxy(#[values(None, Some(""), Some("abc"))] secret: Option<&str>
Ok(())
}

#[ignore]
#[rstest]
#[case(None, Some("my secret"))]
#[case(Some("my secret"), None)]
Expand All @@ -82,6 +83,7 @@ async fn mismatched_secret(
assert!(spawn_client(client_secret).await.is_err());
}

#[ignore]
#[tokio::test]
async fn invalid_address() -> Result<()> {
// We don't need the serial guard for this test because it doesn't create a server.
Expand Down

0 comments on commit 72f8294

Please sign in to comment.