Home
last modified time | relevance | path

Searched full:sleep (Results 1 – 25 of 6066) sorted by relevance

12345678910>>...243

/external/rust/android-crates-io/crates/tokio/tests/
Dtime_sleep.rs28 let sleep = time::sleep(Duration::from_millis(10)); in is_elapsed() localVariable
30 tokio::pin!(sleep); in is_elapsed()
32 assert!(!sleep.is_elapsed()); in is_elapsed()
34 assert!(futures::poll!(sleep.as_mut()).is_pending()); in is_elapsed()
36 assert!(!sleep.is_elapsed()); in is_elapsed()
38 sleep.as_mut().await; in is_elapsed()
40 assert!(sleep.is_elapsed()); in is_elapsed()
75 time::sleep(ms(5)).await; in delayed_sleep_wrapping_level_0()
89 let mut sleep = task::spawn(Box::pin(time::sleep_until(now + ms(100)))); in reset_future_sleep_before_fire() localVariable
90 assert_pending!(sleep.poll()); in reset_future_sleep_before_fire()
[all …]
Dtime_pause.rs7 use tokio::time::{self, Duration, Instant, Sleep};
66 let sleep = rng.gen_range(Duration::from_secs(0)..Duration::from_secs(1)); in paused_time_stress_run() localVariable
67 time::sleep(sleep).await; in paused_time_stress_run()
76 time::sleep(ms(1)).await; in advance_after_poll()
80 let mut sleep = task::spawn(time::sleep_until(start + ms(300))); in advance_after_poll() localVariable
82 assert_pending!(sleep.poll()); in advance_after_poll()
88 assert_pending!(sleep.poll()); in advance_after_poll()
98 let mut sleep = task::spawn(time::sleep_until(start + ms(300))); in sleep_no_poll() localVariable
104 assert_pending!(sleep.poll()); in sleep_no_poll()
114 sleep: Pin<Box<Sleep>>, field
[all …]
/external/toybox/tests/
Dpkill.test16 sleep 1
17 testing "pattern" "pkill yes && sleep 1 && (pgrep yes || echo 'yes')" \
24 sleep 1
25 testing "pattern (multiple)" "pkill yes && sleep 1 &&
30 sleep 1
31 testing "-f pattern (one)" "pkill -f yes && sleep 1 &&
36 sleep 1
37 testing "-f pattern args" "pkill -f \"yes print1\" && sleep 1 &&
44 sleep 1
45 testing "-f pattern (multiple)" "pkill -f yes && sleep 1 &&
[all …]
Dmount.test27 sleep 1 && umount /mnt && test -e /testDir && rmdir /testDir" "" "" ""
30 sleep 1 && umount /mnt && ! test -e /mnt/testDir" "" "" ""
36 sleep 1 && umount /mnt && test -e /testDir && rmdir /testDir" "" "" ""
39 sleep 1 && umount /mnt && ! test -e /mnt/testDir" "" "" ""
44 sleep 1 && umount /mnt && test -e /testDir && rmdir /testDir" "" "" ""
47 sleep 1 && umount /mnt && ! test -e /mnt/testDir" "" "" ""
51 sleep 1 && ! test -e /mnt/testDir && umount /mnt" "" "" ""
55 mkdir /mnt/testDir && sleep 1 && umount /mnt &&
62 cat testDir/testDir2/testFile && sleep 1 && umount testDir' \
66 cat testDir/testDir2/testFile && sleep 1 && umount testDir' \
[all …]
/external/python/cpython3/Lib/test/test_asyncio/
Dtest_taskgroups.py36 await asyncio.sleep(0.1)
40 await asyncio.sleep(0.2)
53 await asyncio.sleep(0.1)
57 await asyncio.sleep(0.2)
62 await asyncio.sleep(0.15)
71 await asyncio.sleep(1)
75 await asyncio.sleep(0.2)
80 await asyncio.sleep(0.15)
97 await asyncio.sleep(0.1)
103 await asyncio.sleep(1)
[all …]
Dtest_timeouts.py19 await asyncio.sleep(10)
28 await asyncio.sleep(10)
41 await asyncio.sleep(10)
54 await asyncio.sleep(10)
63 await asyncio.sleep(0.01)
71 await asyncio.sleep(0.01)
78 await asyncio.sleep(0.01)
88 await asyncio.sleep(10)
98 await asyncio.sleep(0)
108 await asyncio.sleep(0)
[all …]
/external/ltp/testcases/kernel/controllers/freezer/
D00_description.txt2 This bash script tests freezer code by starting a long sleep process.
4 After we cancel the sleep process should eventually reach the thawed
8 This bash script tests freezer code by starting a long sleep process.
9 The sleep process is frozen. We then kill the sleep process.
10 Then we unfreeze the sleep process and see what happens. We expect the
11 sleep process to receive the kill signals and exit almost immediately
15 This bash script tests freezer code by starting a long sleep process.
16 The sleep process is frozen. We then move the sleep process to a THAWED
17 cgroup. We expect moving the sleep process to fail.
27 This bash script tests freezer code by starting a long sleep process.
[all …]
/external/rust/android-crates-io/crates/tokio/src/time/
Dsleep.rs13 /// No work is performed while awaiting on the sleep future to complete. `Sleep`
21 /// Canceling a sleep instance is done by dropping the returned future. No additional
38 /// See the documentation for the [`Sleep`] type for more examples.
48 /// Tokio runtime. That is why `rt.block_on(sleep(...))` will panic,
50 /// Whereas `rt.block_on(async {sleep(...).await})` doesn't panic.
55 /// [`Sleep`]: struct@crate::time::Sleep
62 pub fn sleep_until(deadline: Instant) -> Sleep { in sleep_until() argument
63 Sleep::new_timeout(deadline, trace::caller_location()) in sleep_until()
69 /// analog to `std::thread::sleep`.
71 /// No work is performed while awaiting on the sleep future to complete. `Sleep`
[all …]
/external/pigweed/pw_thread/
Dsleep_facade_test.cc18 #include "pw_thread/sleep.h"
48 TEST(Sleep, SleepForPositiveDuration) { in TEST() argument
49 // Ensure we are in a thread context, meaning we are permitted to sleep. in TEST()
58 TEST(Sleep, SleepForZeroLengthDuration) { in TEST() argument
59 // Ensure we are in a thread context, meaning we are permitted to sleep. in TEST()
62 // Ensure it doesn't sleep when a zero length duration is used. in TEST()
69 TEST(Sleep, SleepForNegativeDuration) { in TEST() argument
70 // Ensure we are in a thread context, meaning we are permitted to sleep. in TEST()
73 // Ensure it doesn't sleep when a negative duration is used. in TEST()
80 TEST(Sleep, SleepUntilFutureWakeupTime) { in TEST() argument
[all …]
/external/llvm/test/CodeGen/AMDGPU/
Dllvm.amdgcn.s.sleep.ll4 declare void @llvm.amdgcn.s.sleep(i32) #0
24 call void @llvm.amdgcn.s.sleep(i32 0)
25 call void @llvm.amdgcn.s.sleep(i32 1)
26 call void @llvm.amdgcn.s.sleep(i32 2)
27 call void @llvm.amdgcn.s.sleep(i32 3)
28 call void @llvm.amdgcn.s.sleep(i32 4)
29 call void @llvm.amdgcn.s.sleep(i32 5)
30 call void @llvm.amdgcn.s.sleep(i32 6)
31 call void @llvm.amdgcn.s.sleep(i32 7)
34 call void @llvm.amdgcn.s.sleep(i32 8)
[all …]
/external/python/python-api-core/tests/unit/retry/
Dtest_retry_unary.py31 @mock.patch("time.sleep", autospec=True)
37 def test_retry_target_success(utcnow, sleep): argument
51 sleep.assert_has_calls([mock.call(0), mock.call(1)])
54 @mock.patch("time.sleep", autospec=True)
60 def test_retry_target_w_on_error(utcnow, sleep): argument
79 sleep.assert_has_calls([mock.call(0), mock.call(1)])
82 @mock.patch("time.sleep", autospec=True)
88 def test_retry_target_non_retryable_error(utcnow, sleep): argument
97 sleep.assert_not_called()
100 @mock.patch("asyncio.sleep", autospec=True)
[all …]
Dtest_retry_streaming.py34 ValueError, match="Sleep generator stopped yielding sleep values"
95 @mock.patch("time.sleep", autospec=True)
96 def test___call___success(self, sleep): argument
120 sleep.assert_not_called()
122 @mock.patch("time.sleep", autospec=True)
123 def test___call___retry(self, sleep): argument
141 @mock.patch("time.sleep", autospec=True)
143 def test___call___retry_hitting_timeout(self, sleep, uniform, use_deadline_arg): argument
176 # Make sure that calls to fake time.sleep() also advance the mocked
181 sleep.side_effect = increase_time
[all …]
/external/python/python-api-core/tests/asyncio/retry/
Dtest_retry_unary_async.py31 @mock.patch("asyncio.sleep", autospec=True)
38 async def test_retry_target_success(utcnow, sleep): argument
52 sleep.assert_has_calls([mock.call(0), mock.call(1)])
55 @mock.patch("asyncio.sleep", autospec=True)
62 async def test_retry_target_w_on_error(utcnow, sleep): argument
83 sleep.assert_has_calls([mock.call(0), mock.call(1)])
86 @mock.patch("asyncio.sleep", autospec=True)
93 async def test_retry_target_non_retryable_error(utcnow, sleep): argument
102 sleep.assert_not_called()
105 @mock.patch("asyncio.sleep", autospec=True)
[all …]
/external/autotest/utils/frozen_chromite/lib/
Dretry_util.py45 def __init__(self, sleep=0, backoff_factor=1, jitter=0): argument
46 if sleep < 0:
47 raise ValueError('sleep must be >= 0: %s' % sleep)
56 self._sleep = sleep
60 def Sleep(self, attempt): member in _RetryDelayStrategy
61 """Sleep to delay the current retry."""
68 # If |jitter| is set, add a random jitter sleep.
74 time.sleep(total)
107 - If |sleep| is given, the delay between the first and second attempts is
108 |sleep| secs.
[all …]
/external/openthread/tests/scripts/expect/
Dposix-rcp-restoration.exp45 sleep 1
73 sleep 1
88 sleep 1
92 sleep 1
96 sleep 1
111 sleep 1
129 sleep 1
142 sleep 1
146 sleep 1
150 sleep 1
[all …]
/external/autotest/server/site_tests/firmware_Cr50OpenWhileAPOff/
Dfirmware_Cr50OpenWhileAPOff.py38 # c2d2 uses cr50 for ec reset. The setting doesn't survive deep sleep.
39 # This test needs ec reset to survive deep sleep to keep the AP off.
72 # deep sleep with just the AP off.
74 # If deep sleep doesn't work at all, we can't run the test.
77 'sleep support')
78 # We can't hold the ec in reset and enter deep sleep. Set the
80 logging.info("deep sleep doesn't work with EC in reset. skipping "
102 Do a deep sleep reset to fix the cr50 console. Then turn the device on.
112 # Toggle dts mode to enter and exit deep sleep
142 time.sleep(self.SHORT_DELAY)
[all …]
/external/linux-kselftest/tools/testing/selftests/net/
Dfcnal-test.sh190 sleep 1
529 sleep 1
559 sleep 1
847 sleep 1
855 sleep 1
863 sleep 1
871 sleep 1
882 sleep 1
890 sleep 1
898 sleep 1
[all …]
/external/python/watchdog/tests/
Dtest_observers_polling.py5 from time import sleep
52 sleep(SLEEP_TIME)
55 sleep(SLEEP_TIME)
58 sleep(SLEEP_TIME)
61 sleep(SLEEP_TIME)
64 sleep(SLEEP_TIME)
67 sleep(SLEEP_TIME)
70 sleep(SLEEP_TIME)
73 sleep(SLEEP_TIME)
76 sleep(SLEEP_TIME)
[all …]
/external/vogar/test/vogar/target/junit4/
DLongTest2.java23 private void sleep() { in sleep() method in LongTest2
25 Thread.sleep(1000 / 4); in sleep()
32 sleep(); in test1()
37 sleep(); in test2()
42 sleep(); in test3()
47 sleep(); in test4()
52 sleep(); in test5()
57 sleep(); in test6()
62 sleep(); in test7()
67 sleep(); in test8()
/external/python/timeout-decorator/tests/
Dtest_timeout_decorator.py18 time.sleep(2)
27 time.sleep(2)
35 time.sleep(2)
43 time.sleep(2)
51 time.sleep(2)
59 time.sleep(0.1)
66 time.sleep(0.5)
74 time.sleep(1)
90 time.sleep(0.1)
102 time.sleep(2)
[all …]
/external/cronet/tot/third_party/rust/chromium_crates_io/vendor/clap-4.5.21/examples/
Dtyped-derive.md12 --sleep <SLEEP> Allow human-readable durations
23 Args { optimization: Some(1), include: None, bind: None, sleep: None, defines: [], port: 22, log_le…
36 Args { optimization: None, include: Some("../hello"), bind: None, sleep: None, defines: [], port: 2…
43 Args { optimization: None, include: None, bind: Some(192.0.0.1), sleep: None, defines: [], port: 22…
55 $ typed-derive --sleep 10s
56 Args { optimization: None, include: None, bind: None, sleep: Some(Duration(10s)), defines: [], port…
58 $ typed-derive --sleep forever
60 error: invalid value 'forever' for '--sleep <SLEEP>': expected number at 0
69 Args { optimization: None, include: None, bind: None, sleep: None, defines: [("Foo", 10), ("Alice",…
88 Args { optimization: None, include: None, bind: None, sleep: None, defines: [], port: 22, log_level…
[all …]
/external/cronet/stable/third_party/rust/chromium_crates_io/vendor/clap-4.5.21/examples/
Dtyped-derive.md12 --sleep <SLEEP> Allow human-readable durations
23 Args { optimization: Some(1), include: None, bind: None, sleep: None, defines: [], port: 22, log_le…
36 Args { optimization: None, include: Some("../hello"), bind: None, sleep: None, defines: [], port: 2…
43 Args { optimization: None, include: None, bind: Some(192.0.0.1), sleep: None, defines: [], port: 22…
55 $ typed-derive --sleep 10s
56 Args { optimization: None, include: None, bind: None, sleep: Some(Duration(10s)), defines: [], port…
58 $ typed-derive --sleep forever
60 error: invalid value 'forever' for '--sleep <SLEEP>': expected number at 0
69 Args { optimization: None, include: None, bind: None, sleep: None, defines: [("Foo", 10), ("Alice",…
88 Args { optimization: None, include: None, bind: None, sleep: None, defines: [], port: 22, log_level…
[all …]
/external/rust/android-crates-io/crates/clap/examples/
Dtyped-derive.md12 --sleep <SLEEP> Allow human-readable durations
23 Args { optimization: Some(1), include: None, bind: None, sleep: None, defines: [], port: 22, log_le…
36 Args { optimization: None, include: Some("../hello"), bind: None, sleep: None, defines: [], port: 2…
43 Args { optimization: None, include: None, bind: Some(192.0.0.1), sleep: None, defines: [], port: 22…
55 $ typed-derive --sleep 10s
56 Args { optimization: None, include: None, bind: None, sleep: Some(Duration(10s)), defines: [], port…
58 $ typed-derive --sleep forever
60 error: invalid value 'forever' for '--sleep <SLEEP>': expected number at 0
69 Args { optimization: None, include: None, bind: None, sleep: None, defines: [("Foo", 10), ("Alice",…
88 Args { optimization: None, include: None, bind: None, sleep: None, defines: [], port: 22, log_level…
[all …]
/external/bcc/examples/usdt_sample/
Dusdt_sample.sh28 sleep 30
32 sleep 30
35 sleep 30
38 sleep 30
41 sleep 30
44 sleep 30
47 sleep 30
50 sleep 30
70 sleep 30
74 sleep 30
[all …]
/external/grpc-grpc/test/core/promise/
Dsleep_test.cc15 #include "src/core/lib/promise/sleep.h"
52 TEST(Sleep, Zzzz) { in TEST() argument
57 // Sleep for one second then set done to true. in TEST()
59 Sleep(done_time), InlineWakeupScheduler(), in TEST()
70 TEST(Sleep, OverlyEagerEventEngine) { in TEST() argument
75 // Schedule a sleep for a very long time. in TEST()
82 Sleep(done_time), InlineWakeupScheduler(), in TEST()
92 // time yet, but sleep should believe the EventEngine. in TEST()
97 TEST(Sleep, AlreadyDone) { in TEST() argument
102 // Sleep for no time at all then set done to true. in TEST()
[all …]

12345678910>>...243