Skip to content

Commit f0254a5

Browse files
committed
Tweak
1 parent 033443f commit f0254a5

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

async-ssh2-lite/tests/integration_tests/remote_port_forwarding.rs

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,15 +69,12 @@ async fn simple_with_tokio() -> Result<(), Box<dyn error::Error>> {
6969
});
7070

7171
//
72+
let mut session =
73+
AsyncSession::<async_ssh2_lite::TokioTcpStream>::connect(ssh_server_connect_addr, None)
74+
.await?;
75+
__run__session__userauth_pubkey_file(&mut session).await?;
7276
let forwarding_task: tokio::task::JoinHandle<Result<(), Box<dyn error::Error + Send + Sync>>> =
7377
tokio::task::spawn(async move {
74-
let mut session = AsyncSession::<async_ssh2_lite::TokioTcpStream>::connect(
75-
ssh_server_connect_addr,
76-
None,
77-
)
78-
.await?;
79-
__run__session__userauth_pubkey_file(&mut session).await?;
80-
8178
match session
8279
.remote_port_forwarding(
8380
remote_port,
@@ -97,7 +94,7 @@ async fn simple_with_tokio() -> Result<(), Box<dyn error::Error>> {
9794
});
9895

9996
//
100-
tokio::time::sleep(tokio::time::Duration::from_millis(200)).await;
97+
tokio::time::sleep(tokio::time::Duration::from_millis(500)).await;
10198

10299
//
103100
let mut session =

0 commit comments

Comments
 (0)