Skip to content

Commit 3cfb152

Browse files
committed
Add failing join_all test
1 parent 9a07811 commit 3cfb152

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

tests/lib.rs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1993,3 +1993,16 @@ async fn test_match_body_asnyc() {
19931993

19941994
assert_eq!(200, response.status());
19951995
}
1996+
1997+
#[tokio::test]
1998+
async fn test_join_all_async() {
1999+
let futures = (0..10).map(|_| async {
2000+
let mut s = Server::new_async().await;
2001+
let m = s.mock("POST", "/").create_async().await;
2002+
2003+
reqwest::Client::new().post(s.url()).send().await.unwrap();
2004+
m.assert_async().await;
2005+
});
2006+
2007+
let _results = futures::future::join_all(futures).await;
2008+
}

0 commit comments

Comments
 (0)