Commit Graph

644 Commits

Author SHA1 Message Date
Adnan Begovic 9b50627030 cmsdk: Provide remaining Profile test coverage.
Change-Id: Ief60939e92c1e8efe700410e3e23a0eeff744364
TICKET: CYNGNOS-3046
2016-06-16 11:08:28 -07:00
Michael Bestas 522b0c3db1 utils: Introduce FileUtils class
Change-Id: Icbfa068fa0db2ae28436063072dd4b576f1b2be1
2016-06-16 10:44:36 -07:00
Luis Vidal 3f8b3b3862 Provide remaining Weather API test coverage
Change-Id: I15acbb4193158e7b2b98f7298b1774e1a1bc0cc2
TICKET: CYNGNOS-3043
2016-06-15 16:52:24 -07:00
Danesh M c701b8ea6e CMSDK : Add tests for ColorUtils
CYNGNOS-3047

Change-Id: Icdea3bd18f80302eb421cbd572abc9e6eeb30f0a
2016-06-15 13:38:40 -07:00
Danesh M 60c6053a92 CMSDK : Fix external view test
Java's assert doesn't really do much on android and just returns true, which
makes you feel good about your tests, but its just lying to you. On the long run
its best that you know the real result and fix it, hence switch to JUnit's assert.

CYNGNOS-3042

Change-Id: If7e5982b10abc1f842a52110973566818b1e3bf4
2016-06-15 13:38:22 -07:00
Danesh M 912410f27d CMSDK : Add LiveLockScreenManager tests
CYNGNOS-3048

Change-Id: I5a372d23028c43a3952199b8ad70854bec2dc7a1
2016-06-15 13:38:03 -07:00
Danesh M b6e71bc544 External view test
CYNGNOS-3042

Change-Id: Ibdd11b631c6deea3eb030ffb1ba55b6ca5fe022b
2016-06-14 13:14:35 -07:00
Scott Mertz aa11b3330a cmsdk: fixup javadoc in CMHardwareManager
Change-Id: I114e57c1b907de3cc7cdaff746b0391cef4b8eb0
2016-06-14 11:54:08 -07:00
Adnan Begovic 7fff40e2d0 cmsdk: Clean up posted tile in CustomTileListenerService test.
TICKET: CYNGNOS-3022
Change-Id: If0c2e18b86c5d2061fd36d404d9e63496998c25f
2016-06-14 11:29:12 -07:00
Adnan Begovic 8387d3cc07 cmsdk: Add CustomTileListenerService tests.
Change-Id: Ife06dc7672efded1d6ce34afce2d3d3954c50d1f
TICKET: CYNGNOS-3022
2016-06-13 11:37:04 -07:00
Adnan Begovic 0e0cb73c61 cmsdk: Provide test coverage to Profile's *Settings classes.
Change-Id: I775cdd00e7e5cfbead681d548075f44d5799bccf
TICKET: CYNGNOS-3027
2016-06-13 11:35:38 -07:00
Adnan Begovic 2add3de267 cmsdk: Provide tests for Profile.ProfileTrigger interfaces.
Change-Id: I2ece6365defdd126c2cce1bbdf1ccc7d671d3a70
TICKET: CYNGNOS-3021
2016-06-13 11:28:07 -07:00
Adnan Begovic fda1fc6843 cmsdk: Provide coverage for serial number and unique device id.
Tests for unique device id are enforced to be implemented correctly
  on user builds.

Change-Id: I1c6b24bbf68fe1dce645744f8323c869fdeb9ada
TICKET: CYNGNOS-3026
2016-06-09 15:37:46 -07:00
d34d b6a21cab09 Keyguard: Get your weather on... the lock screen [2/3]
Change-Id: I1475cdd450021ef1a71c6c888319689e3b0507a3
2016-06-09 14:10:38 -07:00
Roman Birg 5b6638051e CMSettingsProvider: load provisioned flag when creating DB
If the database needs to be created, it will not be upgraded. So, if the
device was provisioned and the table wasn't created, we don't upgrade
and so we cannot bring the old flag to the new location.

Fix this by setting the new cm provisioned flag on database creation.

Ticket: CYNGNOS-3017

Change-Id: I1e961f1cb2d06c55c1e92ef63c6dbaee17dbc304
Signed-off-by: Roman Birg <roman@cyngn.com>
2016-06-09 11:58:55 -07:00
Luis Vidal aa1f592e9f Ensures ProfileTrustAgent properly grants/revokes trust [2/2]
Notifies the ProfileTrustAgent when a WiFi/BT event was triggered even
if no new profile was selected so the trust agent can grant/revoke trust

Filters out the multiple network state change notifications to make sure
we notify the trust agent only when the event that the profile
is tracking actually happened

Change-Id: I047861a8b145762fff24568e341373a89ee01de9
TICKET: CYNGNOS-2719
2016-06-08 17:04:59 -07:00
Diogo Ferreira 19de84cd1b cmsdk: LiveDisplay: Enforce dump permission
Fixes android.security.cts.ServicePermissionsTest#testDumpProtected.

Change-Id: I5641b42c56d9783b1edb8fb397d51040cadb1467
2016-06-07 10:55:45 -07:00
Adnan Begovic 705890212d CMSettingsProvider: Add coverage for CMSettings' interfaces.
TICKET: CYNGNOS-3016
Change-Id: I55b762b51ad98194c235b83c36e3a6683c33ac4e
2016-06-07 10:45:53 -07:00
Adnan Begovic 8cbdd2a58a CMSettingsProvider: Fix defaults test for DEV_FORCE_SHOW_NAVBAR.
Since DEV_FORCE_SHOW_NAVBAR was moved to global, the test needs
  to query its value there.

TICKET: CYNGNOS-3016
Change-Id: Ided274ec065ec989b4ca4f172ec569adb74cbfd5
2016-06-07 10:45:30 -07:00
Adnan Begovic cf8f5cefcb CMSettingsProvider: Register as CMTS package.
Change-Id: I6733d352c47b4abbadc42222d3dd5976db8d36b6
2016-06-07 10:45:13 -07:00
Adnan Begovic 7a48ce3b42 cmsdk: Add test package to CMTS targets.
Change-Id: Iddb3ab6c5361875567e816c004ce4d6c438210ba
2016-06-07 10:43:41 -07:00
Adnan Begovic fb0c0371d4 cmsdk: Fix redundant case in themes contract's componentToImageColName.
TICKET: CYNGNOS-3015
Change-Id: I1daf7cf7b5b2119ab34e69b339644a1fb3da16dc
2016-06-07 10:43:07 -07:00
Adnan Begovic 39f001274e cmsdk: Provide themescontract tests.
TICKET: CYNGNOS-3015
Change-Id: Ice714eb144c7da7e03abd0423f3cfe4b0574067e
2016-06-07 10:42:14 -07:00
inky@build01 c45e01b8ea Automatic translation import
Change-Id: I39e197f19ff2888207f0eae14e72b39a21241eca
2016-06-06 17:44:43 -07:00
Adnan Begovic 70d3b76d2a cmsdk: Add binder transaction id tests for api 5 interfaces.
Change-Id: I693f09266dab763141e3957392fb82c4fb7344a0
2016-06-04 11:56:52 -07:00
clyde@build01 174f042ec7 Automatic translation import
Change-Id: I7cacb61ffe8817360907f7138555f466b9f2f060
2016-06-03 15:14:56 -07:00
Dan Pasanen c4becbb3f4 CMSettings: fix lock screen rotation toggle [3/3]
Change-Id: I2940663c7476b0df9b3553a480fa33ea4f18a5bc
2016-06-03 14:03:50 -07:00
d34d ee069f8c81 Themes: Use default audibles when pkgName is empty
Fixes an issue where audibles would be "unknown" causing them to
not play when phone rings, notifications arive or an alarm goes off

Change-Id: If279ed7e88784c025999822da7ee3a1a51d63bbd
TICKET: CYNGNOS-2728
2016-06-02 10:01:21 -07:00
inky@build01 af55f98056 Automatic translation import
Change-Id: I4c501ae6f8cf5bcdb2957ed920d081b3b8627e3d
2016-06-01 12:02:56 -07:00
Adnan Begovic b51572d697 cmsdk: Create CMSystemServer to handle our platform init.
Change-Id: I7b62978e2a284a3a1ec1ffc1d8c72545d7b0c939
2016-05-31 17:28:48 -07:00
Jessica Wagantall 970f0b6e95 Automatic translation import
Change-Id: I93bbea04f8764c0430597f295fef6972f632be1e
Ticket: RM-214
2016-05-26 18:58:18 -07:00
Jessica Wagantall 5e56748899 Automatic translation import
Change-Id: I46e5d915a803f1ef6813bdbdabe737863025e7ba
Ticket: RM-214
2016-05-20 17:23:32 -07:00
Adnan Begovic ef4a783b6e 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
2016-05-20 15:47:52 -07:00
Abhisek Devkota 8f50ecda5d Automatic translation import
Change-Id: I806c87e9f036c65c25ec56c452fac23507cf643f
2016-05-17 22:12:50 +02:00
d34d 3b4129f1da Expose lock screen blurring as a setting [1/2]
This will provide control over blurring since the current implementation
assumes it is always on provided the device config specifies it
supports blur.

Change-Id: I71e318af12b5212133c6c5b02bed050eb67757d9
TICKET: CYNGNOS-2610
2016-05-16 08:54:01 -07:00
Abhisek Devkota 5cb275d8c1 Automatic translation import
Change-Id: I5728ee43d68ae83f6480664f19f8bafb7d3fcc10
2016-05-15 02:47:41 +02:00
Abhisek Devkota 638da93883 Automatic translation import
Change-Id: Ic62129d6a01476de1cee98a54e5d39e136f80701
2016-05-14 11:18:20 +02:00
Danesh M 68665286e8 CMSettings : Move force_show_navbar to global
Keep feature inline with 12.1, only allow owner to
control the feature and mirror across users.

Also add additional checks for moved settings.

Change-Id: Ida11b71bc5ce9463628f8c5d76e59902d47d59bb
2016-05-13 13:35:13 -07:00
Scott Mertz 6113701337 PerformanceManagerService: drop requests if system is not yet ready
There is a race condition between when onBootPhase(PHASE_SYSTEM_SERVICES_READY)
is handled and when clients request profiles, cpu boost, or launch boost.
Drop these requests in this condition.

OPO-702
Change-Id: I0860f824473767a4a4776e9febc7fb786b81f457
2016-05-12 15:29:27 -07:00
Roman Birg 256a7350ce CMSettings: don't trample user metrics setting on upgrade
During an upgrade, we try to migrate values which are
considered to be LEGACY settings to the new provider, however
because of a bad upgrade path, we need to check if the key exists in the
new database AND the old database, and then we can skip it in that case.

Ticket: CYNGNOS-2740

Change-Id: I5d6bc8399ccc328f4190ed7508c27bd9d5de1b9d
Signed-off-by: Roman Birg <roman@cyngn.com>
2016-05-11 14:45:14 -07:00
d34d 8c8601b9f3 LLS: Fix NPE when backing service dies
The mService member variable should not be used directly as this can
cause an NPE if the backing service has died.  Instead, use the
getServiceGuarded() method which will take care of re-establishing
a connection to the backing service.

Change-Id: I290e69c07a2e56644de7a394543d1e36fac1cbcc
TICKET: CYNGNOS-2779
2016-05-11 11:18:41 -07:00
Abhisek Devkota 5340c0e45b Automatic translation import
Change-Id: I08828c53b07a47fb169871c14b4d91641f88e3eb
Ticket: RM-232
2016-05-10 16:20:55 -07:00
Michael Bestas 69c9ab0f86 Automatic translation import
Change-Id: I415a05f9260dee22c61c2bd8cad035a424990fb6
2016-05-10 18:43:11 +03:00
Michael Bestas 4a0ad7cfbb CMSettings: Fix upgrade from cm-12.1 after weather changes
* Only the owner can write to the global db

Change-Id: Iec7736c28ff0bc7a35dae8bbc85ca2b1c137da49
2016-05-08 01:15:29 +03:00
Steve Kondik b77b8b5a70 cmsdk: Pass the process name and pid for launch boosts
* We need this for vendor perf tools.
 * This also adds a NativeHelper class which loads the JNI
   library on-demand, since we don't have an entry point.

Change-Id: If76ad8f952e86366978ae9cf9d1f107febccc28b
2016-05-06 22:25:21 -07:00
Luis Vidal 186ae8353d Set a default temperature unit
Bump the DB version and set a default temperature unit in
global settings

Change-Id: I14f80e1b3fa3ae4a47769c02b5ebd6a905a53e46
TICKET: CYNGNOS-2751
2016-05-06 17:49:03 -07:00
d34d e4886a668f QS: Make themes a first class citizen again
Change-Id: Icd397a2ddd730ae525233b66288fde9a6798c221
TICKET: CYNGNOS-2670
2016-05-05 14:00:21 -07:00
Pat Erley 9ff5ea9cea cmsdk: Fix CTS Failure due to testDumpProtected
Only dump CMAudio Service State for processes with dump permissions.

OPO-679
Change-Id: I28a501851a76e6d82f5726c13ac1fac74f47a8f1
2016-05-05 12:14:58 -07:00
Roman Birg 10f165d5d0 cmsdk: add persisted key value for status bar tiles
The persisted one simply contains the user, the publishing package, and
the tile tag - items which can be persisted across reboots to restore
the tile's properties on boot properly.

Ticket: CYNGNOS-2530

Change-Id: If770557482e81ab0dd0d16c3ac8be0b2b51e653a
Signed-off-by: Roman Birg <roman@cyngn.com>
2016-05-04 22:31:41 -07:00
d34d 8770189b8d cmsdk: Add allowViaWhitelist to LLS_MANAGER_ACCESS_PRIVATE
Change-Id: Idee5bd602047c01f8e13cd7d5ddbe6fb151215a2
TICKET: CYNGNOS-2378
2016-05-04 17:42:28 -07:00