/aosp14/frameworks/base/core/tests/coretests/src/android/text/format/ |
H A D | RelativeDateTimeFormatterTest.java | 72 getRelativeTimeSpanString(en_US, tz, 0, MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, 0)); in test_getRelativeTimeSpanStringCTS() 163 test_getRelativeTimeSpanString_helper(0 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, in test_getRelativeTimeSpanString() 166 test_getRelativeTimeSpanString_helper(1 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, in test_getRelativeTimeSpanString() 169 test_getRelativeTimeSpanString_helper(2 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, in test_getRelativeTimeSpanString() 172 test_getRelativeTimeSpanString_helper(25 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, in test_getRelativeTimeSpanString() 177 test_getRelativeTimeSpanString_helper(720 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, in test_getRelativeTimeSpanString() 214 test_getRelativeTimeSpanString_helper(30 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, in test_getRelativeTimeSpanString() 402 now - 42 * MINUTE_IN_MILLIS, now, MINUTE_IN_MILLIS, 0)); in test_getRelativeTimeSpanStringGerman() 405 now + 42 * MINUTE_IN_MILLIS, now, MINUTE_IN_MILLIS, 0)); in test_getRelativeTimeSpanStringGerman() 431 now - (42 * MINUTE_IN_MILLIS), now, MINUTE_IN_MILLIS, 0)); in test_getRelativeTimeSpanStringFrench() [all …]
|
/aosp14/frameworks/base/services/tests/mockingservicestests/src/com/android/server/job/controllers/ |
H A D | QuotaControllerTest.java | 468 now - 10 * MINUTE_IN_MILLIS, 9 * MINUTE_IN_MILLIS, 3); in testDeleteObsoleteSessionsLocked() 470 now - (70 * MINUTE_IN_MILLIS), 9 * MINUTE_IN_MILLIS, 1); in testDeleteObsoleteSessionsLocked() 527 now - 10 * MINUTE_IN_MILLIS, 9 * MINUTE_IN_MILLIS, 3); in testOnAppRemovedLocked() 529 now - (70 * MINUTE_IN_MILLIS), 9 * MINUTE_IN_MILLIS, 1); in testOnAppRemovedLocked() 586 now - 10 * MINUTE_IN_MILLIS, 9 * MINUTE_IN_MILLIS, 3); in testOnUserRemovedLocked() 588 now - (70 * MINUTE_IN_MILLIS), 9 * MINUTE_IN_MILLIS, 1); in testOnUserRemovedLocked() 1017 createTimingSession(MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, 2), false); in testGetExecutionStatsLocked_Values_BeginningOfTime() 4920 createTimingSession(MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, 2), true); in testGetRemainingEJExecutionTimeLocked_BeginningOfTime() 5138 createTimingSession(now - 40 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, 5)); in testGetTimeUntilEJQuotaConsumedLocked_WithStaleSessions() 5140 createTimingSession(now - 30 * MINUTE_IN_MILLIS, MINUTE_IN_MILLIS, 5)); in testGetTimeUntilEJQuotaConsumedLocked_WithStaleSessions() [all …]
|
H A D | TimeControllerTest.java | 69 private static final long HOUR_IN_MILLIS = 60 * MINUTE_IN_MILLIS; 453 advanceElapsedClock(10 * MINUTE_IN_MILLIS); in runTestCheckExpiredDelaysAndResetAlarm() 463 advanceElapsedClock(30 * MINUTE_IN_MILLIS); in runTestCheckExpiredDelaysAndResetAlarm() 473 advanceElapsedClock(30 * MINUTE_IN_MILLIS); in runTestCheckExpiredDelaysAndResetAlarm() 510 advanceElapsedClock(10 * MINUTE_IN_MILLIS); in testCheckExpiredDelaysAndResetAlarm_SomeNotReady() 521 advanceElapsedClock(55 * MINUTE_IN_MILLIS); in testCheckExpiredDelaysAndResetAlarm_SomeNotReady() 557 advanceElapsedClock(10 * MINUTE_IN_MILLIS); in runTestCheckExpiredDeadlinesAndResetAlarm() 567 advanceElapsedClock(30 * MINUTE_IN_MILLIS); in runTestCheckExpiredDeadlinesAndResetAlarm() 577 advanceElapsedClock(30 * MINUTE_IN_MILLIS); in runTestCheckExpiredDeadlinesAndResetAlarm() 614 advanceElapsedClock(10 * MINUTE_IN_MILLIS); in testCheckExpiredDeadlinesAndResetAlarm_SomeNotReady() [all …]
|
H A D | PrefetchControllerTest.java | 20 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 245 setDeviceConfigLong(PcConstants.KEY_LAUNCH_TIME_ALLOWANCE_MS, 5 * MINUTE_IN_MILLIS); in testConstantsUpdating_ValidValues() 248 assertEquals(5 * MINUTE_IN_MILLIS, mPrefetchController.getLaunchTimeAllowanceMs()); in testConstantsUpdating_ValidValues() 254 setDeviceConfigLong(PcConstants.KEY_LAUNCH_TIME_THRESHOLD_MS, 4 * MINUTE_IN_MILLIS); in testConstantsUpdating_InvalidValues() 255 setDeviceConfigLong(PcConstants.KEY_LAUNCH_TIME_ALLOWANCE_MS, -MINUTE_IN_MILLIS); in testConstantsUpdating_InvalidValues() 316 .thenReturn(sSystemClock.millis() + MINUTE_IN_MILLIS); in testConstraintSatisfiedWhenLaunchSoon() 338 .thenReturn(sSystemClock.millis() + 10 * MINUTE_IN_MILLIS); in testConstraintSatisfiedWhenTop() 445 SOURCE_PACKAGE, sSystemClock.millis() + MINUTE_IN_MILLIS); in testEstimatedLaunchTimeChangedToSoon() 457 setDeviceConfigLong(PcConstants.KEY_LAUNCH_TIME_ALLOWANCE_MS, 15 * MINUTE_IN_MILLIS); in testEstimatedLaunchTimeAllowance() 485 sSystemClock = getShiftedClock(sSystemClock, HOUR_IN_MILLIS + MINUTE_IN_MILLIS); in testEstimatedLaunchTimeAllowance()
|
H A D | StateControllerTest.java | 59 private static final long MINUTE_IN_MILLIS = 60 * SECOND_IN_MILLIS; field in StateControllerTest 60 private static final long HOUR_IN_MILLIS = 60 * MINUTE_IN_MILLIS;
|
/aosp14/frameworks/base/services/tests/mockingservicestests/src/com/android/server/utils/ |
H A D | AlarmQueueTest.java | 20 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 191 alarmQueue.addAlarm("1", nowElapsed + 5 * MINUTE_IN_MILLIS); 196 alarmQueue.addAlarm("1", nowElapsed + 20 * MINUTE_IN_MILLIS); 200 alarmQueue.addAlarm("1", nowElapsed + 10 * MINUTE_IN_MILLIS); 206 alarmQueue.addAlarm("2", nowElapsed + 11 * MINUTE_IN_MILLIS); 210 alarmQueue.addAlarm("2", nowElapsed + 51 * MINUTE_IN_MILLIS); 214 alarmQueue.addAlarm("1", nowElapsed + 52 * MINUTE_IN_MILLIS); 263 final AlarmQueue<String> alarmQueue = createAlarmQueue(true, 5 * MINUTE_IN_MILLIS); 270 alarmQueue.addAlarm(pkg1, fixedTimeElapsed + MINUTE_IN_MILLIS); 274 advanceElapsedClock(MINUTE_IN_MILLIS); [all …]
|
/aosp14/frameworks/base/services/tests/mockingservicestests/src/com/android/server/utils/quota/ |
H A D | CountQuotaTrackerTest.java | 262 expected1.addLast(now - 10 * MINUTE_IN_MILLIS); in testAppRemoval() 264 expected2.addLast(now - 70 * MINUTE_IN_MILLIS); in testAppRemoval() 293 expected.addLast(now - (70 * MINUTE_IN_MILLIS)); in testUserRemoval() 294 expected.addLast(now - (10 * MINUTE_IN_MILLIS)); in testUserRemoval() 315 logEventAt(now - 5 * MINUTE_IN_MILLIS); in testUpdateExecutionStatsLocked_NoTimer() 316 logEventAt(now - MINUTE_IN_MILLIS); in testUpdateExecutionStatsLocked_NoTimer() 420 logEventAt(now - 5 * MINUTE_IN_MILLIS); in testGetExecutionStatsLocked_Values() 469 mInjector.mElapsedTime = 3 * MINUTE_IN_MILLIS; in testGetExecutionStatsLocked_Values_BeginningOfTime() 472 logEventAt(MINUTE_IN_MILLIS); in testGetExecutionStatsLocked_Values_BeginningOfTime() 473 logEventAt(2 * MINUTE_IN_MILLIS); in testGetExecutionStatsLocked_Values_BeginningOfTime() [all …]
|
/aosp14/frameworks/base/services/tests/mockingservicestests/src/com/android/server/job/ |
H A D | JobSchedulerServiceTest.java | 1211 advanceElapsedClock(6 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1229 advanceElapsedClock(30 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1235 advanceElapsedClock(20 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1241 advanceElapsedClock(6 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1271 advanceElapsedClock(15 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1277 advanceElapsedClock(30 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1289 advanceElapsedClock(MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1297 advanceElapsedClock(29 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1309 advanceElapsedClock(6 * MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() 1321 advanceElapsedClock(MINUTE_IN_MILLIS); in testGetRescheduleJobForPeriodic_closeToEndOfWindow() [all …]
|
/aosp14/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/utils/ |
H A D | StringUtilTest.java | 46 final double testMillis = 5 * DateUtils.MINUTE_IN_MILLIS + 30 * DateUtils.SECOND_IN_MILLIS; in testFormatElapsedTime_WithSeconds_ShowSeconds() 55 final double testMillis = 5 * DateUtils.MINUTE_IN_MILLIS + 30 * DateUtils.SECOND_IN_MILLIS; in testFormatElapsedTime_NoSeconds_DoNotShowSeconds() 65 + 4 * DateUtils.HOUR_IN_MILLIS + 15 * DateUtils.MINUTE_IN_MILLIS; in testFormatElapsedTime_TimeMoreThanOneDay_ShowCorrectly() 75 + 4 * DateUtils.HOUR_IN_MILLIS + 15 * DateUtils.MINUTE_IN_MILLIS; in testFormatElapsedTime_TimeMoreThanOneDayAndCollapseTimeUnit_ShowCorrectly() 84 final double testMillis = 2 * DateUtils.DAY_IN_MILLIS + 15 * DateUtils.MINUTE_IN_MILLIS; in testFormatElapsedTime_ZeroFieldsInTheMiddleDontShow() 111 final double testMillis = 15 * DateUtils.MINUTE_IN_MILLIS; in testFormatElapsedTime_onlyContainsMinute_hasTtsSpan() 163 final double testMillis = 2 * DateUtils.MINUTE_IN_MILLIS; in testFormatRelativeTime_TwoMinutes_withSeconds() 172 final double testMillis = 119 * DateUtils.MINUTE_IN_MILLIS; in testFormatRelativeTime_LessThanTwoHours_withSeconds()
|
/aosp14/frameworks/base/services/tests/servicestests/src/com/android/server/tare/ |
H A D | LedgerTest.java | 20 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 77 final long start = now - 10 * HOUR_IN_MILLIS + i * MINUTE_IN_MILLIS; in testInitialization_FullLists() 79 start, start + MINUTE_IN_MILLIS, 1, null, 400, 0); in testInitialization_FullLists() 107 final long start = now - MINUTE_IN_MILLIS; in testInitialization_FullLists() 134 start, start + MINUTE_IN_MILLIS, 1, null, 400, 0); in testInitialization_OverflowingLists() 231 now - 5 * MINUTE_IN_MILLIS, now - MINUTE_IN_MILLIS, 1, null, 400, 0); in testRemoveOldTransactions() 287 start, start + MINUTE_IN_MILLIS, 1, null, 400, 0); in testTransactionsAlwaysInOrder() 296 start, start + MINUTE_IN_MILLIS, 1, null, 4800, 0); in testTransactionsAlwaysInOrder() 299 start, start + MINUTE_IN_MILLIS, 1, null, 600, 0); in testTransactionsAlwaysInOrder() 302 start, start + MINUTE_IN_MILLIS, 1, null, 600, 0); in testTransactionsAlwaysInOrder() [all …]
|
/aosp14/frameworks/base/services/tests/servicestests/src/com/android/server/people/data/ |
H A D | ConversationStoreTest.java | 198 3L * DateUtils.MINUTE_IN_MILLIS); in testDataPersistenceAndRestoration() 205 mMockScheduledExecutorService.fastForwardTime(3L * DateUtils.MINUTE_IN_MILLIS); in testDataPersistenceAndRestoration() 229 mMockScheduledExecutorService.fastForwardTime(3L * DateUtils.MINUTE_IN_MILLIS); in testDelayedDiskWrites() 235 mMockScheduledExecutorService.fastForwardTime(DateUtils.MINUTE_IN_MILLIS); in testDelayedDiskWrites() 244 mMockScheduledExecutorService.fastForwardTime(3L * DateUtils.MINUTE_IN_MILLIS); in testDelayedDiskWrites() 248 mMockScheduledExecutorService.fastForwardTime(3L * DateUtils.MINUTE_IN_MILLIS); in testDelayedDiskWrites()
|
/aosp14/frameworks/base/core/java/android/widget/ |
H A D | DateTimeView.java | 21 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 261 if (duration < MINUTE_IN_MILLIS) { 263 mUpdateTimeMillis = mTimeMillis + MINUTE_IN_MILLIS + 1; 266 count = (int)(duration / MINUTE_IN_MILLIS); 271 millisIncrease = MINUTE_IN_MILLIS; 379 if (duration < MINUTE_IN_MILLIS) { in onInitializeAccessibilityNodeInfoInternal() 382 count = (int)(duration / MINUTE_IN_MILLIS); in onInitializeAccessibilityNodeInfoInternal()
|
/aosp14/frameworks/base/core/tests/utiltests/src/com/android/internal/util/ |
H A D | FileRotatorTest.java | 21 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 123 currentTime += MINUTE_IN_MILLIS; in testRotate() 143 mBasePath, PREFIX, MINUTE_IN_MILLIS, DAY_IN_MILLIS); in testDelete() 151 currentTime += MINUTE_IN_MILLIS + SECOND_IN_MILLIS; in testDelete() 161 currentTime = TEST_TIME + DAY_IN_MILLIS + (2 * MINUTE_IN_MILLIS); in testDelete() 173 mBasePath, PREFIX, MINUTE_IN_MILLIS, DAY_IN_MILLIS); in testThrowRestoresBackup()
|
/aosp14/frameworks/base/core/java/android/text/format/ |
H A D | RelativeDateTimeFormatter.java | 48 public static final long MINUTE_IN_MILLIS = SECOND_IN_MILLIS * 60; field in RelativeDateTimeFormatter 49 public static final long HOUR_IN_MILLIS = MINUTE_IN_MILLIS * 60; 148 if (duration < MINUTE_IN_MILLIS && minResolution < MINUTE_IN_MILLIS) { in getRelativeTimeSpanString() 152 count = (int) (duration / MINUTE_IN_MILLIS); in getRelativeTimeSpanString()
|
H A D | DateUtils.java | 55 public static final long MINUTE_IN_MILLIS = SECOND_IN_MILLIS * 60; field in DateUtils 56 public static final long HOUR_IN_MILLIS = MINUTE_IN_MILLIS * 60; 279 return getRelativeTimeSpanString(startTime, System.currentTimeMillis(), MINUTE_IN_MILLIS); in getRelativeTimeSpanString() 421 } else if (millis >= MINUTE_IN_MILLIS) { in formatDuration() 422 final int minutes = (int) ((millis + 30000) / MINUTE_IN_MILLIS); in formatDuration()
|
/aosp14/frameworks/base/apex/jobscheduler/service/java/com/android/server/job/controllers/ |
H A D | QuotaController.java | 20 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 407 private static final long MAX_PERIOD_MS = 24 * 60 * MINUTE_IN_MILLIS; 1897 inQuotaTimeElapsed = nowElapsed + 5 * MINUTE_IN_MILLIS; 3138 MINUTE_IN_MILLIS; 3709 long newTopReward = Math.min(15 * MINUTE_IN_MILLIS, 3999 long newExemptLimitMs = Math.max(15 * MINUTE_IN_MILLIS, 4006 long newActiveLimitMs = Math.max(15 * MINUTE_IN_MILLIS, 4013 long newWorkingLimitMs = Math.max(15 * MINUTE_IN_MILLIS, 4020 long newFrequentLimitMs = Math.max(10 * MINUTE_IN_MILLIS, 4027 long newRareLimitMs = Math.max(10 * MINUTE_IN_MILLIS, [all …]
|
/aosp14/frameworks/base/services/core/java/com/android/server/am/ |
H A D | DropboxRateLimiter.java | 33 private static final long RATE_LIMIT_BUFFER_DURATION = 10 * DateUtils.MINUTE_IN_MILLIS; 43 private static final long STRICT_RATE_LIMIT_BUFFER_DURATION = 20 * DateUtils.MINUTE_IN_MILLIS;
|
/aosp14/frameworks/base/services/core/java/com/android/server/notification/ |
H A D | CountdownConditionProvider.java | 124 DateUtils.getRelativeTimeSpanString(mTime, now, DateUtils.MINUTE_IN_MILLIS); in onSubscribe() 179 DateUtils.getRelativeTimeSpanString(time, now, DateUtils.MINUTE_IN_MILLIS); in tryParseDescription()
|
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/util/leak/ |
H A D | GarbageMonitor.java | 109 15 * DateUtils.MINUTE_IN_MILLIS; // 15 min 110 private static final long HEAP_TRACK_INTERVAL = 1 * DateUtils.MINUTE_IN_MILLIS; // 1 min 280 (float) GARBAGE_INSPECTION_INTERVAL / DateUtils.MINUTE_IN_MILLIS)); in dump() 281 final float htiMins = HEAP_TRACK_INTERVAL / DateUtils.MINUTE_IN_MILLIS; in dump()
|
/aosp14/frameworks/base/services/core/java/com/android/server/utils/ |
H A D | AlarmQueue.java | 19 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 60 private static final long SIGNIFICANT_TRIGGER_TIME_CHANGE_THRESHOLD_MS = MINUTE_IN_MILLIS;
|
/aosp14/frameworks/base/services/core/java/com/android/server/locksettings/recoverablekeystore/storage/ |
H A D | RemoteLockscreenValidationSessionStorage.java | 39 private static final long SESSION_TIMEOUT_MILLIS = 10L * DateUtils.MINUTE_IN_MILLIS;
|
/aosp14/frameworks/base/services/core/java/com/android/server/location/gnss/ |
H A D | GnssMetrics.java | 392 stats.getLoggingDurationMs() / ((double) DateUtils.MINUTE_IN_MILLIS)).append( in dumpGnssMetricsAsText() 399 t[1] / ((double) DateUtils.MINUTE_IN_MILLIS)).append("\n"); in dumpGnssMetricsAsText() 403 t[0] / ((double) DateUtils.MINUTE_IN_MILLIS)).append("\n"); in dumpGnssMetricsAsText()
|
/aosp14/frameworks/base/services/core/java/com/android/server/apphibernation/ |
H A D | HibernationStateDiskStore.java | 49 private static final long DISK_WRITE_DELAY = 1L * DateUtils.MINUTE_IN_MILLIS;
|
/aosp14/frameworks/base/services/core/java/com/android/server/utils/quota/ |
H A D | QuotaTracker.java | 19 import static android.text.format.DateUtils.MINUTE_IN_MILLIS; 149 static final long MAX_WINDOW_SIZE_MS = 30 * 24 * 60 * MINUTE_IN_MILLIS; // 1 month
|
/aosp14/frameworks/base/core/tests/coretests/src/com/android/internal/util/ |
H A D | TokenBucketTest.java | 60 drain(new TokenBucket((int) DateUtils.MINUTE_IN_MILLIS, 50), 50); in testInitialCapacity()
|