am 9b694bed: am 70071d01: am 3fefecef: Merge "Add test for checking max users > 1 if managed users feature enabled" into lmp-sprout-dev
* commit '9b694bedec7cc85892618c554f55982589a0e895':
Add test for checking max users > 1 if managed users feature enabled
diff --git a/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/ManagedProfileTest.java b/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/ManagedProfileTest.java
index 7c07c40..862322a 100644
--- a/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/ManagedProfileTest.java
+++ b/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/ManagedProfileTest.java
@@ -92,6 +92,14 @@
assertFalse(listUsers().contains(mUserId));
}
+ public void testMaxUsersStrictlyMoreThanOne() throws Exception {
+ if (hasDeviceFeature("android.software.managed_users")) {
+ assertTrue("Device must support more than 1 user "
+ + "if android.software.managed_users feature is available",
+ getMaxNumberOfUsersSupported() > 1);
+ }
+ }
+
public void testCrossProfileIntentFilters() throws Exception {
if (!mHasFeature) {
return;