From 15f0b634921a0de14cda0b969ec9a5cf41311c98 Mon Sep 17 00:00:00 2001 From: Rob Ede Date: Sat, 8 Mar 2025 17:37:40 +0000 Subject: [PATCH] test: fix panic in tokio stream construction --- actix-server/tests/testing_server.rs | 4 +++- justfile | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/actix-server/tests/testing_server.rs b/actix-server/tests/testing_server.rs index ab3dc3f8..2b5b5418 100644 --- a/actix-server/tests/testing_server.rs +++ b/actix-server/tests/testing_server.rs @@ -71,5 +71,7 @@ async fn new_with_builder() { srv.connect().unwrap(); // connect to alt service defined in custom ServerBuilder - TcpStream::from_std(net::TcpStream::connect(alt_addr).unwrap()).unwrap(); + let stream = net::TcpStream::connect(alt_addr).unwrap(); + stream.set_nonblocking(true).unwrap(); + TcpStream::from_std(stream).unwrap(); } diff --git a/justfile b/justfile index 8d00a935..8f227955 100644 --- a/justfile +++ b/justfile @@ -73,7 +73,7 @@ test-all toolchain="": (test toolchain) (test-docs toolchain) doc *args: && doc-set-workspace-crates rm -f "$(cargo metadata --format-version=1 | jq -r '.target_directory')/doc/crates.js" RUSTDOCFLAGS="--cfg=docsrs -Dwarnings" cargo +nightly doc --no-deps --workspace {{ all_crate_features }} {{ args }} - + [private] doc-set-workspace-crates: #!/usr/bin/env bash