Re-enable some test cases

Re-enable some test cases now the case they test has been
renabled (by commit 3d7a4143d5).

Tested with:

make -j30 FrameworksServicesTests
adb install -r -g \
  "out/target/product/angler/data/app/FrameworksServicesTests/FrameworksServicesTests.apk"
adb shell am instrument -e package com.android.server.timezone -w \
  com.android.frameworks.servicestests \
  "com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner"

Bug: 31008728
Test: See above
Change-Id: Ia26c4355e41d5b1010594a06bb8c4e8cef8528f7
This commit is contained in:
Neil Fuller
2017-07-18 10:30:53 +01:00
parent 899a1f23c5
commit 29ff71baa4

View File

@@ -198,26 +198,25 @@ public class PackageTrackerTest {
mFakeIntentHelper.assertReliabilityTriggeringDisabled();
}
// TODO(nfuller): Uncomment or delete when it's clear what will happen with http://b/35995024
// @Test
// public void trackingEnabled_updateAppNotPrivileged() throws Exception {
// // Set up device configuration.
// configureTrackingEnabled();
// configureReliabilityConfigSettingsOk();
// configureUpdateAppPackageNotPrivileged(UPDATE_APP_PACKAGE_NAME);
// configureDataAppPackageOk(DATA_APP_PACKAGE_NAME);
//
// try {
// // Initialize the tracker.
// mPackageTracker.start();
// fail();
// } catch (RuntimeException expected) {}
//
// mFakeIntentHelper.assertNotInitialized();
//
// // Check reliability triggering state.
// mFakeIntentHelper.assertReliabilityTriggeringDisabled();
// }
@Test
public void trackingEnabled_updateAppNotPrivileged() throws Exception {
// Set up device configuration.
configureTrackingEnabled();
configureReliabilityConfigSettingsOk();
configureUpdateAppPackageNotPrivileged(UPDATE_APP_PACKAGE_NAME);
configureDataAppPackageOk(DATA_APP_PACKAGE_NAME);
try {
// Initialize the tracker.
mPackageTracker.start();
fail();
} catch (RuntimeException expected) {}
mFakeIntentHelper.assertNotInitialized();
// Check reliability triggering state.
mFakeIntentHelper.assertReliabilityTriggeringDisabled();
}
@Test
public void trackingEnabled_dataAppConfigMissing() throws Exception {
@@ -239,26 +238,25 @@ public class PackageTrackerTest {
mFakeIntentHelper.assertReliabilityTriggeringDisabled();
}
// TODO(nfuller): Uncomment or delete when it's clear what will happen with http://b/35995024
// @Test
// public void trackingEnabled_dataAppNotPrivileged() throws Exception {
// // Set up device configuration.
// configureTrackingEnabled();
// configureReliabilityConfigSettingsOk();
// configureUpdateAppPackageOk(UPDATE_APP_PACKAGE_NAME);
// configureDataAppPackageNotPrivileged(DATA_APP_PACKAGE_NAME);
//
// try {
// // Initialize the tracker.
// mPackageTracker.start();
// fail();
// } catch (RuntimeException expected) {}
//
// mFakeIntentHelper.assertNotInitialized();
//
// // Check reliability triggering state.
// mFakeIntentHelper.assertReliabilityTriggeringDisabled();
// }
@Test
public void trackingEnabled_dataAppNotPrivileged() throws Exception {
// Set up device configuration.
configureTrackingEnabled();
configureReliabilityConfigSettingsOk();
configureUpdateAppPackageOk(UPDATE_APP_PACKAGE_NAME);
configureDataAppPackageNotPrivileged(DATA_APP_PACKAGE_NAME);
try {
// Initialize the tracker.
mPackageTracker.start();
fail();
} catch (RuntimeException expected) {}
mFakeIntentHelper.assertNotInitialized();
// Check reliability triggering state.
mFakeIntentHelper.assertReliabilityTriggeringDisabled();
}
@Test
public void trackingEnabled_packageUpdate_badUpdateAppManifestEntry() throws Exception {