summaryrefslogtreecommitdiffstats
path: root/tokio/tests/process_issue_2174.rs
diff options
context:
space:
mode:
authorIvan Petkov <ivanppetkov@gmail.com>2020-09-06 20:30:40 -0700
committerGitHub <noreply@github.com>2020-09-07 03:30:40 +0000
commit842d5565bdd4310cd96386a8ffa9949b24c5856f (patch)
tree33ce4fd24247ad7b4e65a1341961580f4baf1af9 /tokio/tests/process_issue_2174.rs
parentd74eabc7d795afa8ca2cd9170977d47131e12ee0 (diff)
process: add Child::{wait,try_wait} (#2796)
* add Child::try_wait to mirror the std API * replace Future impl on Child with `.wait()` method to bring our APIs closer to those in std and it allow us to internally fuse the future so that repeated calls to `wait` result in the same value (similar to std) without forcing the caller to fuse the outer future * Also change `Child::id` to return an Option result to avoid allowing the caller to accidentally use the pid on Unix systems after the child has been reaped * Also remove deprecated Child methods
Diffstat (limited to 'tokio/tests/process_issue_2174.rs')
-rw-r--r--tokio/tests/process_issue_2174.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/tokio/tests/process_issue_2174.rs b/tokio/tests/process_issue_2174.rs
index b5a63cee..d12825f6 100644
--- a/tokio/tests/process_issue_2174.rs
+++ b/tokio/tests/process_issue_2174.rs
@@ -40,7 +40,7 @@ async fn issue_2174() {
// Kill the child process.
child.kill().unwrap();
- let _ = child.await;
+ let _ = child.wait().await;
assert_err!(handle.await);
}