diff options
author | 2025-02-25 11:47:45 -0800 | |
---|---|---|
committer | 2025-02-25 11:47:45 -0800 | |
commit | 1f96aeb3601db0b74efab74e33ad162fc45773d5 (patch) | |
tree | 0a38582bbd05aad7ec25d248dac3546b2fd0d7bd | |
parent | e7f3a29f2e0776ef16151e88557666a428fd3c18 (diff) | |
parent | 22a9ab7a49b717899025bf2fea96c401f804c194 (diff) |
Merge "Fix flaky test, BatteryStatsHistoryTest.startNextFragment" into main
-rw-r--r-- | services/tests/powerstatstests/src/com/android/server/power/stats/BatteryStatsHistoryTest.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/services/tests/powerstatstests/src/com/android/server/power/stats/BatteryStatsHistoryTest.java b/services/tests/powerstatstests/src/com/android/server/power/stats/BatteryStatsHistoryTest.java index 8fad93184732..5165e34c7fcd 100644 --- a/services/tests/powerstatstests/src/com/android/server/power/stats/BatteryStatsHistoryTest.java +++ b/services/tests/powerstatstests/src/com/android/server/power/stats/BatteryStatsHistoryTest.java @@ -456,6 +456,8 @@ public class BatteryStatsHistoryTest { } private void fillActiveFile(BatteryStatsHistory history) { + awaitCompletion(); // Wait for BatteryHistoryDirectory.trim if necessary. + // Create roughly 1K of history int initialSize = history.getHistoryUsedSize(); while (history.getHistoryUsedSize() < initialSize + 1000) { |