summaryrefslogtreecommitdiff
path: root/tests/PackageWatchdog
diff options
context:
space:
mode:
authorZimuzo <zezeozue@google.com>2019-04-05 12:03:10 +0100
committerZimuzo <zezeozue@google.com>2019-04-08 11:33:14 +0100
commit7c6c28f18b81340f6ff79321c92259e95ccf4677 (patch)
tree72f908249b49f4df3dbea2c3a2a87135c48e8ef7 /tests/PackageWatchdog
parente0283ded0a7b2a2010f614943f939e1adc81ebeb (diff)
Allow different explicit health and package expiry timeouts
We have always evaluated the explicit health check results on package expiry. Since I29e2d619a5296716c29893ab3aa2f35f69bfb4d7 we now receive explicit health check timeouts from ExtServices. This cl doesn't yet use the timeout but it treats explicit health check timeouts as different events from package expiry. This is in preparation to use the timeouts from the cl mentioned above. Improved readability: Logging, comments, variable and function names Bug: 120598832 Test: atest PackageWatchdogTest Change-Id: I8030dae1fef5b8fee42095c1eaf16861cc33ac59
Diffstat (limited to 'tests/PackageWatchdog')
-rw-r--r--tests/PackageWatchdog/src/com/android/server/PackageWatchdogTest.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/PackageWatchdog/src/com/android/server/PackageWatchdogTest.java b/tests/PackageWatchdog/src/com/android/server/PackageWatchdogTest.java
index 33bb4cceb3a9..b308982c2343 100644
--- a/tests/PackageWatchdog/src/com/android/server/PackageWatchdogTest.java
+++ b/tests/PackageWatchdog/src/com/android/server/PackageWatchdogTest.java
@@ -661,8 +661,10 @@ public class PackageWatchdogTest {
if (mIsEnabled) {
packages.retainAll(mSupportedPackages);
mRequestedPackages.addAll(packages);
+ mSupportedConsumer.accept(mSupportedPackages);
+ } else {
+ mSupportedConsumer.accept(Collections.emptyList());
}
- mSupportedConsumer.accept(mSupportedPackages);
}
public void setSupportedPackages(List<String> packages) {