Home
last modified time | relevance | path

Searched refs:waitUntil (Results 1 – 25 of 73) sorted by relevance

123

/cts/tests/tests/batterysaving/src/android/os/cts/batterysaving/
DBatterySaverTest.java25 import static com.android.compatibility.common.util.TestUtils.waitUntil;
200 waitUntil("Location mode didn't change to " in testAutomotiveProjectionExceptions()
205 waitUntil("UI mode didn't change to " + Configuration.UI_MODE_NIGHT_YES, in testAutomotiveProjectionExceptions()
216 waitUntil("UI mode didn't change to " + Configuration.UI_MODE_NIGHT_NO, in testAutomotiveProjectionExceptions()
232 waitUntil("UI mode didn't change to " + Configuration.UI_MODE_NIGHT_YES, in testAutomotiveProjectionExceptions()
261 waitUntil("Location mode didn't change to " in testGlobalSettings()
266 waitUntil("UI mode didn't change to " + Configuration.UI_MODE_NIGHT_YES, in testGlobalSettings()
288 waitUntil("Location mode didn't change to " in testDeviceConfig()
293 waitUntil("UI mode didn't change to " + Configuration.UI_MODE_NIGHT_YES, in testDeviceConfig()
316 waitUntil("Location mode didn't change to " in testGlobalSettingsOverridesDeviceConfig()
[all …]
DBatterySavingTestBase.java23 import static com.android.compatibility.common.util.TestUtils.waitUntil;
102 waitUntil("Force all apps standby still " + !expected + " (alarm)", () -> in waitUntilAlarmForceAppStandby()
107 waitUntil("Force all apps standby still " + !expected + " (job)", () -> { in waitUntilJobForceAppStandby()
123 waitUntil("Force background check still " + !expected + " (job)", () -> in waitUntilForceBackgroundCheck()
/cts/hostsidetests/devicepolicy/app/DeviceAndProfileOwner/src/com/android/cts/deviceandprofileowner/
DAudioRestrictionTest.java74 waitUntil(false, mCheckIfMasterVolumeMuted); in testDisallowAdjustVolume_muted()
80 waitUntil(true, mCheckIfMasterVolumeMuted); in testDisallowAdjustVolume_muted()
114 waitUntil(true, mCheckIfMasterVolumeMuted); in testDisallowAdjustVolume()
123 waitUntil(false, mCheckIfMasterVolumeMuted); in testDisallowAdjustVolume()
127 waitUntil(2, new Callable<Integer>() { in testDisallowAdjustVolume()
137 waitUntil(false, mCheckIfMasterVolumeMuted); in testDisallowAdjustVolume()
160 waitUntil(true, new Callable<Boolean>() { in testDisallowUnmuteMicrophone()
173 waitUntil(false, new Callable<Boolean>() { in testDisallowUnmuteMicrophone()
182 private <T> void waitUntil(T expected, Callable<T> c) throws Exception { in waitUntil() method in AudioRestrictionTest
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/
DBatteryUtils.java20 import static com.android.compatibility.common.util.TestUtils.waitUntil;
94 waitUntil("Device still " + (pluggedIn ? " not plugged" : " plugged"), in waitForPlugStatus()
136 waitUntil("Battery saver still off", () -> getPowerManager().isPowerSaveMode()); in enableBatterySaver()
144 waitUntil("Battery saver still on", () -> !getPowerManager().isPowerSaveMode()); in enableBatterySaver()
158 waitUntil("Battery saver still on", () -> !getPowerManager().isPowerSaveMode()); in resetBatterySaver()
167 waitUntil("Device still not interactive", () -> getPowerManager().isInteractive()); in turnOnScreen()
171 waitUntil("Device still interactive", () -> !getPowerManager().isInteractive()); in turnOnScreen()
DTestUtils.java52 public static void waitUntil(String message, BooleanSupplierWithThrow predicate) in waitUntil() method in TestUtils
54 waitUntil(message, 0, predicate); in waitUntil()
60 public static void waitUntil( in waitUntil() method in TestUtils
DAmMonitor.java104 final long waitUntil = SystemClock.uptimeMillis() + timeout; in waitFor() local
109 if (now >= waitUntil) { in waitFor()
115 mPendingLines.wait(waitUntil - now); in waitFor()
/cts/tests/inputmethod/util/src/android/view/inputmethod/cts/util/
DInputMethodVisibilityVerifier.java62 private static boolean waitUntil(long timeout, @NonNull Predicate<UiAutomation> condition) { in waitUntil() method in InputMethodVisibilityVerifier
101 assertTrue(waitUntil(timeout, InputMethodVisibilityVerifier::containsWatermark)); in expectImeVisible()
112 assertTrue(message, waitUntil(timeout, InputMethodVisibilityVerifier::containsWatermark)); in expectImeVisible()
125 assertTrue(waitUntil(timeout, InputMethodVisibilityVerifier::notContainsWatermark)); in expectImeInvisible()
/cts/tests/framework/base/windowmanager/util/src/android/server/wm/
DInputMethodVisibilityVerifier.java58 private static boolean waitUntil(long timeout, @NonNull Predicate<UiAutomation> condition) { in waitUntil() method in InputMethodVisibilityVerifier
97 assertTrue(waitUntil(timeout, InputMethodVisibilityVerifier::containsWatermark)); in expectImeVisible()
110 assertTrue(waitUntil(timeout, InputMethodVisibilityVerifier::notContainsWatermark)); in expectImeInvisible()
/cts/hostsidetests/car/src/android/car/cts/
DUiModeHostTest.java93 waitUntil(() -> isNightMode(), "the night mode"); in waitUntilNightMode()
97 waitUntil(() -> !isNightMode(), "the day mode"); in waitUntilDayMode()
/cts/tests/app/src/android/app/cts/android/app/cts/tools/
DWatchUidRunner.java142 long waitUntil = SystemClock.uptimeMillis() + timeout; in expect() local
143 String[] line = waitForNextLine(waitUntil, cmd, procState, 0); in expect()
184 long waitUntil = SystemClock.uptimeMillis() + timeout; in waitFor() local
186 String[] line = waitForNextLine(waitUntil, cmd, procState, capability); in waitFor()
244 String[] waitForNextLine(long waitUntil, int cmd, String procState, Integer capability) { in waitForNextLine() argument
249 if (now >= waitUntil) { in waitForNextLine()
257 mPendingLines.wait(waitUntil - now); in waitForNextLine()
/cts/hostsidetests/appsecurity/test-apps/UseProcessSuccess/src/com/android/cts/useprocess/
DAccessNetworkTest.java51 long waitUntil = SystemClock.uptimeMillis() + 5000; in waitForResult() local
55 if (now >= waitUntil) { in waitForResult()
59 wait(waitUntil - now); in waitForResult()
/cts/hostsidetests/car/util/src/android/car/cts/
DCarHostJUnit4TestCase.java372 CommonTestUtils.waitUntil("timed out waiting for user " + userId + " initialization", in waitForUserInitialized()
380 CommonTestUtils.waitUntil("timed out waiting for car service", in waitForCarServiceReady()
438 CommonTestUtils.waitUntil("timed out (" + DEFAULT_TIMEOUT_SEC in waitUntilCurrentUser()
451 waitUntil(() -> getLastActiveUserId() == userId, in waitForUserSwitchCompleted()
470 CommonTestUtils.waitUntil("timed out (" + timeoutSec + "s) waiting for current user to NOT " in waitUntilCurrentUserIsNotSystem()
479 waitUntil(timeoutSec, () -> getAllPersistentUsers().size() >= n, "%d persistent users", n); in waitUntilAtLeastNPersistentUsersAreAvailable()
485 protected void waitUntil(long timeoutSeconds, BooleanSupplierWithThrow<Exception> predicate, in waitUntil() method in CarHostJUnit4TestCase
487 CommonTestUtils.waitUntil("timed out (" + timeoutSeconds + "s) waiting for " in waitUntil()
495 protected void waitUntil(BooleanSupplierWithThrow<Exception> predicate, in waitUntil() method in CarHostJUnit4TestCase
497 waitUntil(DEFAULT_TIMEOUT_SEC, predicate, msgPattern, msgArgs); in waitUntil()
/cts/tests/tests/syncmanager/src/android/content/syncmanager/cts/
DCtsSyncManagerTest.java25 import static com.android.compatibility.common.util.TestUtils.waitUntil;
158 waitUntil("Dumpsys still mentions " + ACCOUNT_1_A, DEFAULT_TIMEOUT_SECONDS, in removeAllAccounts()
175 waitUntil("Syncable isn't initialized", DEFAULT_TIMEOUT_SECONDS, in addAccountAndLetInitialSyncRun()
178 waitUntil("Periodic sync should set up", DEFAULT_TIMEOUT_SECONDS, in addAccountAndLetInitialSyncRun()
236 waitUntil("Should retry more than 3 times.", DEFAULT_TIMEOUT_SECONDS, () -> { in testSoftErrorRetriesActiveApp()
264 waitUntil("Expedited job sync didn't run in Doze", 30, () -> { in testExpeditedJobSync()
295 waitUntil("Expedited job sync should still run in Doze", 30, () -> { in testExpeditedJobSync_InDoze()
348 waitUntil("Doze mode didn't change to " + (on ? "on" : "off"), 10, in setDozeState()
/cts/tests/JobScheduler/src/android/jobscheduler/cts/
DNotificationTest.java22 import static com.android.compatibility.common.util.TestUtils.waitUntil;
99 waitUntil("Notification wasn't posted", 15 /* seconds */, in testNotificationJobEndDetach()
136 waitUntil("Notification wasn't posted", 15 /* seconds */, in testNotificationJobEndRemove()
148 waitUntil("Notification wasn't removed", 15 /* seconds */, in testNotificationJobEndRemove()
424 waitUntil("Notification wasn't posted", 15 /* seconds */, in testUserInitiatedJobNotificationBehavior()
433 waitUntil("A user-initiated job notification should not be cancellable by apps.", in testUserInitiatedJobNotificationBehavior()
476 waitUntil("Notification wasn't posted", 15 /* seconds */, in testNonUserInitiatedJobNotificationBehavior()
485 waitUntil("A non user-initiated job notification should be cancellable by apps.", in testNonUserInitiatedJobNotificationBehavior()
DTestNotificationListener.java19 import static com.android.compatibility.common.util.TestUtils.waitUntil;
82 waitUntil("Notification listener not instantiated", 15 /* seconds */, in getInstance()
161 waitUntil("Notification wasn't removed", 15 /* seconds */, in assertNotificationsRemoved()
DNetworkingHelper.java23 import static com.android.compatibility.common.util.TestUtils.waitUntil;
261 waitUntil("Airplane mode didn't change to " + (on ? " on" : " off"), 60 /* seconds */, in setAirplaneMode()
298 waitUntil("Data saver " + (enabled ? "not enabled" : "still enabled"), in setDataSaverEnabled()
309 waitUntil("Location " + (wantEnabled ? "not enabled" : "still enabled"), in setLocationMode()
353 waitUntil("Failed to enable Wifi", 30 /* seconds */, in setWifiState()
/cts/tests/framework/base/windowmanager/src/android/server/wm/multidisplay/
DMultiDisplaySecurityTests.java625 TestUtils.waitUntil("Waiting for system decoration flag to be set", in testSettingFlagWithoutInternalSystemPermission()
640 TestUtils.waitUntil("Waiting for show IME flag to be set", in testSettingFlagWithoutInternalSystemPermission()
695 TestUtils.waitUntil("Waiting for system decoration flag to be set", in testSettingFlagToUntrustedDisplay()
713 TestUtils.waitUntil("Waiting for show IME flag to be set", in testSettingFlagToUntrustedDisplay()
763 TestUtils.waitUntil("Waiting for system decoration flag to be set", in testSettingFlagToTrustedDisplay()
771 TestUtils.waitUntil("Waiting for system decoration flag to be set", in testSettingFlagToTrustedDisplay()
785 TestUtils.waitUntil("Waiting for show IME flag to be set", in testSettingFlagToTrustedDisplay()
793 TestUtils.waitUntil("Waiting for show IME flag to be set", in testSettingFlagToTrustedDisplay()
802 TestUtils.waitUntil("Waiting for show IME flag to be set", in testSettingFlagToTrustedDisplay()
/cts/tests/tests/display/src/android/display/cts/
DHdrConversionEnabledTest.java189 waitUntil(mDisplayManager -> mDisplayManager.getHdrConversionMode().getConversionMode() in testGetSupportedHdrOutputTypesWithAppOverride()
196 waitUntil(mDisplayManager -> mDisplayManager.getHdrConversionMode().getConversionMode() in testGetSupportedHdrOutputTypesWithAppOverride()
203 waitUntil(mDisplayManager -> mDisplayManager.getHdrConversionMode().getConversionMode() in testGetSupportedHdrOutputTypesWithAppOverride()
209 waitUntil(mDisplayManager -> mDisplayManager.getHdrConversionMode().getConversionMode() in testGetSupportedHdrOutputTypesWithAppOverride()
228 private void waitUntil(Predicate<DisplayManager> pred, Duration maxWait) in waitUntil() method in HdrConversionEnabledTest
/cts/hostsidetests/graphics/displaymode/app/src/com/android/cts/graphics/displaymode/
DBootDisplayModeTest.java115 waitUntil(display, in testGetBootDisplayMode()
162 waitUntil(display, in testClearBootDisplayMode()
174 waitUntil(display, in testClearBootDisplayMode()
191 private void waitUntil(Display display, Predicate<Display> pred, Duration maxWait) in waitUntil() method in BootDisplayModeTest
/cts/tests/AlarmManager/util/src/android/alarmmanager/util/
DAlarmManagerDeviceConfigHelper.java19 import static com.android.compatibility.common.util.TestUtils.waitUntil;
95 waitUntil("Could not update config within " + UPDATE_TIMEOUT_SECONDS in commitAndAwaitPropagation()
/cts/tests/tests/os/src/android/os/cts/
DPowerManagerTest.java21 import static com.android.compatibility.common.util.TestUtils.waitUntil;
176 waitUntil("PowerManager doesn't think the device has connected power", in testPowerManager_batteryDischargePrediction()
187 waitUntil("PowerManager still thinks the device has connected power", in testPowerManager_batteryDischargePrediction()
/cts/tests/tests/syncmanager/apps/app1/src/android/content/syncmanager/cts/app/
DSyncManagerCtsAuthenticator.java18 import static com.android.compatibility.common.util.TestUtils.waitUntil;
90 waitUntil("Accounts still exist.", in removeAllAccounts()
/cts/tests/tests/shortcutmanager/src/android/content/pm/cts/shortcutmanager/
DShortcutManagerSpoofingTest.java26 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.waitUntil;
114 waitUntil("Launcher 2 didn't receive message", () -> in testSpoofingLauncher()
/cts/tests/tests/contactsprovider/src/android/provider/cts/contacts/
DContactsContract_SimContactTest.java123 TestUtils.waitUntil("Broadcast has not been received in time", ASYNC_TIMEOUT_LIMIT_SEC, in testAddSimAccount_broadcastsChange()
145 TestUtils.waitUntil("Broadcast has not been received in time", ASYNC_TIMEOUT_LIMIT_SEC, in testRemoveSimAccount_broadcastsChange()
/cts/tests/tests/batterysaving/src/android/os/cts/deviceidle/
DDeviceIdleTest.java18 import static com.android.compatibility.common.util.TestUtils.waitUntil;
88 waitUntil("Never made it to IDLE state", 30 /* seconds */, () -> { in testLightIdleMode()

123