Merge "Fixes Instrument cluster permissions - upgraded privileges to system user"
diff --git a/tests/DirectRenderingClusterSample/AndroidManifest.xml b/tests/DirectRenderingClusterSample/AndroidManifest.xml
index 2dcdc58..12c6bba 100644
--- a/tests/DirectRenderingClusterSample/AndroidManifest.xml
+++ b/tests/DirectRenderingClusterSample/AndroidManifest.xml
@@ -16,8 +16,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="android.car.cluster.sample"
- android:versionCode="1"
- android:versionName="1.0">
+ android:sharedUserId="android.uid.system">
<uses-sdk android:targetSdkVersion="25" android:minSdkVersion="25"/>
diff --git a/tests/DirectRenderingClusterSample/src/android/car/cluster/sample/MainClusterActivity.java b/tests/DirectRenderingClusterSample/src/android/car/cluster/sample/MainClusterActivity.java
index 3e123e4..c8bff38 100644
--- a/tests/DirectRenderingClusterSample/src/android/car/cluster/sample/MainClusterActivity.java
+++ b/tests/DirectRenderingClusterSample/src/android/car/cluster/sample/MainClusterActivity.java
@@ -247,7 +247,7 @@
Intent intent = new Intent(this, ClusterRenderingServiceImpl.class);
intent.setAction(LOCAL_BINDING_ACTION);
- bindService(intent, mClusterRenderingServiceConnection, 0);
+ bindServiceAsUser(intent, mClusterRenderingServiceConnection, 0, UserHandle.SYSTEM);
registerFacet(new Facet<>(findViewById(R.id.btn_nav), 0, NavigationFragment.class));
registerFacet(new Facet<>(findViewById(R.id.btn_phone), 1, PhoneFragment.class));