/frameworks/base/services/tests/servicestests/src/com/android/server/devicepolicy/ |
D | SystemUpdatePolicyTest.java | 52 import java.util.concurrent.TimeUnit; 276 assertInstallationOption(SystemUpdatePolicy.TYPE_PAUSE, TimeUnit.HOURS.toMillis(2), in testInstallationOptionWithoutFreeze() 280 SystemUpdatePolicy.TYPE_INSTALL_AUTOMATIC, TimeUnit.HOURS.toMillis(1), in testInstallationOptionWithoutFreeze() 281 millis_2018_01_01 + TimeUnit.HOURS.toMillis(2), p); in testInstallationOptionWithoutFreeze() 283 assertInstallationOption(SystemUpdatePolicy.TYPE_PAUSE, TimeUnit.HOURS.toMillis(22), in testInstallationOptionWithoutFreeze() 284 millis_2018_01_01 + TimeUnit.HOURS.toMillis(4), p); in testInstallationOptionWithoutFreeze() 288 assertInstallationOption(SystemUpdatePolicy.TYPE_PAUSE, TimeUnit.HOURS.toMillis(1), in testInstallationOptionWithoutFreeze() 289 millis_2018_01_01 + TimeUnit.HOURS.toMillis(21), p); in testInstallationOptionWithoutFreeze() 292 SystemUpdatePolicy.TYPE_INSTALL_AUTOMATIC, TimeUnit.HOURS.toMillis(2), in testInstallationOptionWithoutFreeze() 295 assertInstallationOption(SystemUpdatePolicy.TYPE_PAUSE, TimeUnit.HOURS.toMillis(19), in testInstallationOptionWithoutFreeze() [all …]
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | NitzDataTest.java | 27 import java.util.concurrent.TimeUnit; 51 assertEquals(TimeUnit.MINUTES.toMillis(-1 * 15), nitz.getLocalOffsetMillis()); in testParse_withDst() 58 assertEquals(TimeUnit.MINUTES.toMillis(8 * 15), nitz.getLocalOffsetMillis()); in testParse_withDst() 59 assertEquals(TimeUnit.HOURS.toMillis(1), nitz.getDstAdjustmentMillis().longValue()); in testParse_withDst() 65 assertEquals(TimeUnit.MINUTES.toMillis(-8 * 15), nitz.getLocalOffsetMillis()); in testParse_withDst() 66 assertEquals(TimeUnit.HOURS.toMillis(1), nitz.getDstAdjustmentMillis().longValue()); in testParse_withDst() 76 assertEquals(TimeUnit.MINUTES.toMillis(4 * 15), nitz.getLocalOffsetMillis()); in testParse_noDstField() 83 assertEquals(TimeUnit.MINUTES.toMillis(-4 * 15), nitz.getLocalOffsetMillis()); in testParse_noDstField() 93 assertEquals(TimeUnit.MINUTES.toMillis(-32 * 15), nitz.getLocalOffsetMillis()); in testParse_androidEmulatorTimeZoneExtension() 94 assertEquals(TimeUnit.HOURS.toMillis(1), nitz.getDstAdjustmentMillis().longValue()); in testParse_androidEmulatorTimeZoneExtension()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/usage/ |
D | AppTimeLimitControllerTests.java | 42 import java.util.concurrent.TimeUnit; 349 assertFalse(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testAppUsageObserver_Accumulation() 357 assertTrue(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testAppUsageObserver_Accumulation() 384 assertFalse(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testUsageSessionObserver_Accumulation() 392 assertTrue(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testUsageSessionObserver_Accumulation() 419 assertFalse(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testAppUsageLimitObserver_Accumulation() 427 assertTrue(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testAppUsageLimitObserver_Accumulation() 436 assertFalse(mLimitReachedLatch.await(6_000L, TimeUnit.MILLISECONDS)); in testAppUsageObserver_TimeoutOtherApp() 439 assertFalse(mLimitReachedLatch.await(100L, TimeUnit.MILLISECONDS)); in testAppUsageObserver_TimeoutOtherApp() 448 assertFalse(mLimitReachedLatch.await(6_000L, TimeUnit.MILLISECONDS)); in testUsageSessionObserver_TimeoutOtherApp() [all …]
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/am/ |
D | AppCompactorTest.java | 45 import java.util.concurrent.TimeUnit; 211 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in useCompaction_listensToDeviceConfigChanges() 221 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in useCompaction_listensToDeviceConfigChanges() 235 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in useCompaction_listensToDeviceConfigChangesBadValues() 257 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in compactAction_listensToDeviceConfigChanges() 277 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in compactAction_listensToDeviceConfigChangesBadValues() 290 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in compactAction_listensToDeviceConfigChangesBadValues() 322 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in compactThrottle_listensToDeviceConfigChanges() 349 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in compactThrottle_listensToDeviceConfigChangesBadValues() 367 assertThat(mCountDown.await(5, TimeUnit.SECONDS)).isTrue(); in compactThrottle_listensToDeviceConfigChangesBadValues() [all …]
|
/frameworks/base/core/tests/coretests/src/android/transition/ |
D | FadeTransitionTest.java | 36 import java.util.concurrent.TimeUnit; 54 assertTrue(latch.startLatch.await(400, TimeUnit.MILLISECONDS)); in testFadeOutAndIn() 58 assertTrue(latch.endLatch.await(800, TimeUnit.MILLISECONDS)); in testFadeOutAndIn() 64 assertTrue(latch.startLatch.await(400, TimeUnit.MILLISECONDS)); in testFadeOutAndIn() 70 assertTrue(latch.endLatch.await(800, TimeUnit.MILLISECONDS)); in testFadeOutAndIn() 82 assertTrue(outLatch.startLatch.await(400, TimeUnit.MILLISECONDS)); in testFadeOutInterrupt() 89 assertTrue(inLatch.startLatch.await(400, TimeUnit.MILLISECONDS)); in testFadeOutInterrupt() 97 assertTrue(inLatch.endLatch.await(800, TimeUnit.MILLISECONDS)); in testFadeOutInterrupt() 115 assertTrue(inLatch.startLatch.await(400, TimeUnit.MILLISECONDS)); in testFadeInInterrupt() 122 assertTrue(outLatch.startLatch.await(400, TimeUnit.MILLISECONDS)); in testFadeInInterrupt() [all …]
|
/frameworks/opt/telephony/src/java/com/android/internal/telephony/cat/ |
D | Duration.java | 33 public TimeUnit timeUnit; 35 public enum TimeUnit { enum in Duration 42 TimeUnit(int value) { in TimeUnit() method in Duration.TimeUnit 55 public Duration(int timeInterval, TimeUnit timeUnit) { in Duration() 62 timeUnit = TimeUnit.values()[in.readInt()]; in Duration()
|
/frameworks/base/core/tests/coretests/src/android/animation/ |
D | EventsTest.java | 34 import java.util.concurrent.TimeUnit; 290 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartCancel() 311 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartEnd() 332 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartDelayedCancel() 353 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartDelayedEnd() 374 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testPlayingCancel() 395 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testPlayingEnd() 417 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testPlayingDelayedCancel() 439 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testPlayingDelayedEnd() 463 mFuture.get(getTimeout() + 100, TimeUnit.MILLISECONDS); in testPlayingDelayedCancelMidDelay() [all …]
|
D | ViewPropertyAnimatorTest.java | 37 import java.util.concurrent.TimeUnit; 215 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartCancel() 236 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartDelayedCancel() 257 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testPlayingCancel() 279 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testPlayingDelayedCancel() 303 mFuture.get(getTimeout() + 100, TimeUnit.MILLISECONDS); in testPlayingDelayedCancelMidDelay() 325 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartDoubleCancel() 347 mFuture.get(getTimeout(), TimeUnit.MILLISECONDS); in testStartDelayedDoubleCancel()
|
/frameworks/base/apct-tests/perftests/multiuser/src/android/multiuser/ |
D | UserLifecycleTests.java | 44 import java.util.concurrent.TimeUnit; 109 latch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in createAndStartUser() 146 boolean success = latch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in switchUser_stopped() 183 latch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in stopUser() 205 latch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in lockedBootCompleted() 225 latch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in managedProfileUnlock() 244 latch1.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in managedProfileUnlock_stopped() 253 latch2.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in managedProfileUnlock_stopped() 284 latch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in ephemeralUserStopped() 287 switchLatch.await(TIMEOUT_IN_SECOND, TimeUnit.SECONDS); in ephemeralUserStopped() [all …]
|
/frameworks/base/services/core/java/com/android/server/ |
D | PreloadsFileCacheExpirationJobService.java | 33 import java.util.concurrent.TimeUnit; 53 long keepPreloadsMinTimeoutMs = DEBUG ? TimeUnit.MINUTES.toMillis(2) in schedule() 54 : TimeUnit.DAYS.toMillis(keepPreloadsMinDays); in schedule() 55 long keepPreloadsMaxTimeoutMs = DEBUG ? TimeUnit.MINUTES.toMillis(3) in schedule() 56 : TimeUnit.DAYS.toMillis(keepPreloadsMinDays + 1); in schedule()
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/nitz/ |
D | TimeZoneLookupHelperTest.java | 42 import java.util.concurrent.TimeUnit; 72 int lonSummerOffsetMillis = (int) TimeUnit.HOURS.toMillis(1); in testLookupByNitzByNitz() 73 int lonSummerDstOffsetMillis = (int) TimeUnit.HOURS.toMillis(1); in testLookupByNitzByNitz() 113 int mtvSummerOffsetMillis = (int) TimeUnit.HOURS.toMillis(-8); in testLookupByNitzByNitz() 114 int mtvSummerDstOffsetMillis = (int) TimeUnit.HOURS.toMillis(1); in testLookupByNitzByNitz() 117 int mtvWinterOffsetMillis = (int) TimeUnit.HOURS.toMillis(-7); in testLookupByNitzByNitz() 226 int expectedUtcOffset = (int) TimeUnit.HOURS.toMillis(2); in testLookupByNitzCountry_dstKnownAndUnknown() 227 Integer expectedDstOffset = (int) TimeUnit.HOURS.toMillis(1); in testLookupByNitzCountry_dstKnownAndUnknown() 254 int expectedUtcOffset = (int) TimeUnit.HOURS.toMillis(1); in testLookupByNitzCountry_dstKnownAndUnknown() 281 int expectedUtcOffset = (int) TimeUnit.HOURS.toMillis(2); in testLookupByNitzCountry_dstKnownAndUnknown() [all …]
|
/frameworks/base/services/core/java/com/android/server/location/ |
D | ContextHubServiceTransaction.java | 23 import java.util.concurrent.TimeUnit; 100 /* package */ long getTimeout(TimeUnit unit) { in getTimeout() 103 return unit.convert(30L, TimeUnit.SECONDS); in getTimeout() 110 return unit.convert(5L, TimeUnit.SECONDS); in getTimeout()
|
/frameworks/base/tests/UiBench/src/com/android/test/uibench/ |
D | SlowNestedRecyclerViewActivity.java | 31 import java.util.concurrent.TimeUnit; 37 private static final long INNER_ITEM_CREATE_NS = TimeUnit.MILLISECONDS.toNanos(6); 38 private static final long INNER_ITEM_BIND_NS = TimeUnit.MILLISECONDS.toNanos(1); 39 private static final long INNER_ITEM_ATTACH_NS = TimeUnit.MILLISECONDS.toNanos(1); 41 private static final long OUTER_ITEM_CREATE_NS = TimeUnit.MILLISECONDS.toNanos(3); 42 private static final long OUTER_ITEM_BIND_NS = TimeUnit.MILLISECONDS.toNanos(1); 43 private static final long OUTER_ITEM_ATTACH_NS = TimeUnit.MILLISECONDS.toNanos(1);
|
/frameworks/base/cmds/statsd/tools/loadtest/src/com/android/statsd/loadtest/ |
D | LoadtestActivity.java | 54 import com.android.internal.os.StatsdConfigProto.TimeUnit; 89 private static final Map<String, TimeUnit> TIME_UNIT_MAP = initializeTimeUnitMap(); 110 private static Map<String, TimeUnit> initializeTimeUnitMap() { in initializeTimeUnitMap() 111 Map<String, TimeUnit> labels = new HashMap(); in initializeTimeUnitMap() 112 labels.put("1m", TimeUnit.ONE_MINUTE); in initializeTimeUnitMap() 113 labels.put("5m", TimeUnit.FIVE_MINUTES); in initializeTimeUnitMap() 114 labels.put("10m", TimeUnit.TEN_MINUTES); in initializeTimeUnitMap() 115 labels.put("30m", TimeUnit.THIRTY_MINUTES); in initializeTimeUnitMap() 116 labels.put("1h", TimeUnit.ONE_HOUR); in initializeTimeUnitMap() 117 labels.put("3h", TimeUnit.THREE_HOURS); in initializeTimeUnitMap() [all …]
|
/frameworks/base/core/tests/coretests/src/android/os/ |
D | BinderProxyCountingTest.java | 43 import java.util.concurrent.TimeUnit; 143 if (!bindLatch.await(BIND_SERVICE_TIMEOUT_SEC, TimeUnit.SECONDS)) { in bindService() 239 if (binderLimitLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testBinderProxyLimitBoundary() 246 if (!binderLimitLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testBinderProxyLimitBoundary() 275 if (!binderLimitLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testSetBinderProxyLimit() 305 if (!firstBinderLimitLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testRearmCallbackThreshold() 321 if (secondBinderLimitLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testRearmCallbackThreshold() 336 if (!secondBinderLimitLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testRearmCallbackThreshold() 369 if (!binderDeathLatch.await(TOO_MANY_BINDERS_TIMEOUT_SEC, TimeUnit.SECONDS)) { in testKillBadBehavingApp()
|
/frameworks/base/services/robotests/src/com/android/server/location/ |
D | NtpTimeHelperTest.java | 25 import java.util.concurrent.TimeUnit; 64 assertThat(mCountDownLatch.await(2, TimeUnit.SECONDS)).isTrue(); in handleInjectNtpTime_cachedAgeLow_injectTime() 77 assertThat(mCountDownLatch.await(2, TimeUnit.SECONDS)).isFalse(); in handleInjectNtpTime_injectTimeFailed_injectTimeDelayed() 87 assertThat(mCountDownLatch.await(2, TimeUnit.SECONDS)).isTrue(); in handleInjectNtpTime_injectTimeFailed_injectTimeDelayed() 96 mCountDownLatch.await(1, TimeUnit.SECONDS); in waitForTasksToBePostedOnHandlerAndRunThem()
|
/frameworks/base/tests/utils/testutils/java/com/android/internal/util/test/ |
D | BroadcastInterceptingContext.java | 34 import java.util.concurrent.TimeUnit; 55 assertNotReceived(5, TimeUnit.SECONDS); in assertNotReceived() 58 public abstract void assertNotReceived(long timeout, TimeUnit unit) in assertNotReceived() 89 return get(5, TimeUnit.SECONDS); in get() 98 assertNotReceived(5, TimeUnit.SECONDS); in assertNotReceived() 101 public void assertNotReceived(long timeout, TimeUnit unit) in assertNotReceived()
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/ |
D | BlockingQueueIntentReceiver.java | 23 import java.util.concurrent.TimeUnit; 35 return mQueue.poll(10, TimeUnit.SECONDS); in waitForIntent() 39 return mQueue.poll(3, TimeUnit.SECONDS); in waitForIntentShortDelay()
|
/frameworks/base/core/tests/coretests/src/android/view/ |
D | ViewRootSurfaceCallbackTest.java | 36 import java.util.concurrent.TimeUnit; 41 private static final long TIMEOUT_MS = TimeUnit.SECONDS.toMillis(3); 73 mTidOfSurfaceCreated.get(TIMEOUT_MS, TimeUnit.MILLISECONDS).intValue()); in testCallingTidOfSurfaceCallback() 80 mTidOfSurfaceDestroyed.get(TIMEOUT_MS, TimeUnit.MILLISECONDS).intValue()); in testCallingTidOfSurfaceCallback()
|
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/ |
D | DevicePolicyConstants.java | 22 import java.util.concurrent.TimeUnit; 95 DAS_DIED_SERVICE_RECONNECT_BACKOFF_SEC_KEY, TimeUnit.HOURS.toSeconds(1)); in DevicePolicyConstants() 101 DAS_DIED_SERVICE_RECONNECT_MAX_BACKOFF_SEC_KEY, TimeUnit.DAYS.toSeconds(1)); in DevicePolicyConstants() 105 TimeUnit.MINUTES.toSeconds(2)); in DevicePolicyConstants()
|
D | SecurityLogMonitor.java | 19 import static java.util.concurrent.TimeUnit.MILLISECONDS; 20 import static java.util.concurrent.TimeUnit.NANOSECONDS; 37 import java.util.concurrent.TimeUnit; 85 private static final long RATE_LIMIT_INTERVAL_MS = TimeUnit.HOURS.toMillis(2); 89 private static final long BROADCAST_RETRY_INTERVAL_MS = TimeUnit.MINUTES.toMillis(30); 93 private static final long POLLING_INTERVAL_MS = TimeUnit.MINUTES.toMillis(1); 97 private static final long OVERLAP_NS = TimeUnit.SECONDS.toNanos(3); 100 private static final long FORCE_FETCH_THROTTLE_NS = TimeUnit.SECONDS.toNanos(10); 168 mMonitorThread.join(TimeUnit.SECONDS.toMillis(5)); in stop()
|
/frameworks/layoutlib/create/src/com/android/tools/layoutlib/java/ |
D | System_Delegate.java | 21 import java.util.concurrent.TimeUnit; 58 return TimeUnit.NANOSECONDS.toMillis(mNanosTime.get()); in currentTimeMillis() 66 return TimeUnit.NANOSECONDS.toMillis(mBootNanosTime.get()); in bootTimeMillis()
|
/frameworks/base/services/core/java/com/android/server/notification/ |
D | RankingReconsideration.java | 18 import java.util.concurrent.TimeUnit; 64 public long getDelay(TimeUnit unit) { in getDelay() 65 return unit.convert(mDelay, TimeUnit.MILLISECONDS); in getDelay()
|
/frameworks/layoutlib/bridge/tests/src/android/util/imagepool/ |
D | ImagePoolImplTest.java | 27 import java.util.concurrent.TimeUnit; 63 assertTrue(countDownLatch.await(TIMEOUT_SEC, TimeUnit.SECONDS)); in testImageDispose() 78 assertTrue(cd.await(TIMEOUT_SEC, TimeUnit.SECONDS)); in testImageDisposeFromFunction() 105 assertTrue(countDownLatch1.await(TIMEOUT_SEC, TimeUnit.SECONDS)); in testImageDisposedAndRecycled() 124 assertTrue(countDownLatch2.await(TIMEOUT_SEC, TimeUnit.SECONDS)); in testImageDisposedAndRecycled() 149 assertTrue(countDownLatch.await(TIMEOUT_SEC, TimeUnit.SECONDS)); in testBufferedImageReleased() 217 cd1.await(TIMEOUT_SEC, TimeUnit.SECONDS); in testImageMultipleCopies() 250 cd1.await(TIMEOUT_SEC, TimeUnit.SECONDS); in testPoolDispose()
|
/frameworks/base/core/java/android/metrics/ |
D | MetricsReader.java | 31 import java.util.concurrent.TimeUnit; 172 mTimeMillis = TimeUnit.MILLISECONDS.convert( in Event() 173 nativeEvent.getTimeNanos(), TimeUnit.NANOSECONDS); in Event() 211 long horizonNs = TimeUnit.NANOSECONDS.convert(horizonMs, TimeUnit.MILLISECONDS); in readEvents()
|