From ef4a783b6e9e177d1e1cbd13c700ba57fcb37bd6 Mon Sep 17 00:00:00 2001 From: Adnan Begovic Date: Fri, 20 May 2016 15:45:54 -0700 Subject: [PATCH] cmsdk: Skip powersave during testing. Since powersave is ignored while the device is plugged in, and switching pluggedmodes via runtime executing dumpsys commands is blocked by sepolicy. Ignore the powersave portion of the test. Change-Id: Ia2b206649a7fc1960cc25d16ffd22379e7c616e3 TICKET: CYNGNOS-2603 --- .../cyanogenmod/tests/power/unit/PerfomanceManagerTest.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/src/org/cyanogenmod/tests/power/unit/PerfomanceManagerTest.java b/tests/src/org/cyanogenmod/tests/power/unit/PerfomanceManagerTest.java index ade7bea..8d9f627 100644 --- a/tests/src/org/cyanogenmod/tests/power/unit/PerfomanceManagerTest.java +++ b/tests/src/org/cyanogenmod/tests/power/unit/PerfomanceManagerTest.java @@ -77,7 +77,8 @@ public class PerfomanceManagerTest extends AndroidTestCase { // Identify what power profiles are supported. The api currently returns // the total number of profiles supported in an ordered manner, thus we can // assume what they are and if we can set everything correctly. - for (int powerProfile = 0; powerProfile < + // TODO: Don't skip powersave. Skipped due to powersave being ignored while device plugged + for (int powerProfile = 1; powerProfile < PerformanceManager.POSSIBLE_POWER_PROFILES.length; powerProfile++) { if (powerProfile < mCMPerformanceManager.getNumberOfProfiles()) { //It is supported, set it and test if it was set