CTS change for process capability.

In ActivityManagerProcessStateTest.java, in foreground service with
location type test cases, when process state changes,
also wait for process capability change, especially watch for
PROCESS_CAPABILITY_FOREGROUND_LOCAION.

Create a test app ActivityManagerApi29 with targetSdkVersion set to 29.
In ActivityManagerApi29Test.java, create test case testFgsLocationWithAppOps()
to test PROCESS_CAPABILITY_FOREGROUND_LOCAION is sent to AppOpsService and
AppOpsService can use it to allow or deny OP_COARSE_LOCATION based on
the uid's process state and capability.

Bug: 136274596
Test: atest android.app.cts.ActivityManagerApi29Test
Change-Id: I437c6772112840b6e9ba917c38cc0972d2139221
12 files changed