summaryrefslogtreecommitdiffstats
path: root/tokio/tests
diff options
context:
space:
mode:
authorJuan Alvarez <j@yabit.io>2020-09-07 13:56:15 -0500
committerGitHub <noreply@github.com>2020-09-07 20:56:15 +0200
commit38ec4845d14c25b9d89cb6fbdf2a5c5472971fc3 (patch)
tree906c5aadb8f39072aed6db614ea95f6830e1d864 /tokio/tests
parent842d5565bdd4310cd96386a8ffa9949b24c5856f (diff)
sync: rename `Notify::notify()` -> `notify_one()` (#2822)
Closes: #2813
Diffstat (limited to 'tokio/tests')
-rw-r--r--tokio/tests/sync_notify.rs14
1 files changed, 7 insertions, 7 deletions
diff --git a/tokio/tests/sync_notify.rs b/tokio/tests/sync_notify.rs
index be39ce32..8c70fe39 100644
--- a/tokio/tests/sync_notify.rs
+++ b/tokio/tests/sync_notify.rs
@@ -13,7 +13,7 @@ fn notify_notified_one() {
let notify = Notify::new();
let mut notified = spawn(async { notify.notified().await });
- notify.notify();
+ notify.notify_one();
assert_ready!(notified.poll());
}
@@ -24,7 +24,7 @@ fn notified_one_notify() {
assert_pending!(notified.poll());
- notify.notify();
+ notify.notify_one();
assert!(notified.is_woken());
assert_ready!(notified.poll());
}
@@ -38,7 +38,7 @@ fn notified_multi_notify() {
assert_pending!(notified1.poll());
assert_pending!(notified2.poll());
- notify.notify();
+ notify.notify_one();
assert!(notified1.is_woken());
assert!(!notified2.is_woken());
@@ -50,7 +50,7 @@ fn notified_multi_notify() {
fn notify_notified_multi() {
let notify = Notify::new();
- notify.notify();
+ notify.notify_one();
let mut notified1 = spawn(async { notify.notified().await });
let mut notified2 = spawn(async { notify.notified().await });
@@ -58,7 +58,7 @@ fn notify_notified_multi() {
assert_ready!(notified1.poll());
assert_pending!(notified2.poll());
- notify.notify();
+ notify.notify_one();
assert!(notified2.is_woken());
assert_ready!(notified2.poll());
@@ -76,7 +76,7 @@ fn notified_drop_notified_notify() {
assert_pending!(notified2.poll());
- notify.notify();
+ notify.notify_one();
assert!(notified2.is_woken());
assert_ready!(notified2.poll());
}
@@ -90,7 +90,7 @@ fn notified_multi_notify_drop_one() {
assert_pending!(notified1.poll());
assert_pending!(notified2.poll());
- notify.notify();
+ notify.notify_one();
assert!(notified1.is_woken());
assert!(!notified2.is_woken());