diff options
-rw-r--r-- | AndroidManifest.xml | 5 | ||||
-rw-r--r-- | tests/AndroidTest.xml | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/AndroidManifest.xml b/AndroidManifest.xml index a382b75..0556b06 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -6,6 +6,7 @@ <uses-feature android:name="android.hardware.usb.host"/> <uses-permission android:name="android.permission.ACCESS_MTP"/> <uses-permission android:name="android.permission.FOREGROUND_SERVICE"/> + <uses-permission android:name="android.permission.FOREGROUND_SERVICE_DATA_SYNC"/> <uses-permission android:name="android.permission.MANAGE_USB"/> <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/> <uses-permission android:name="android.permission.MANAGE_USERS"/> @@ -28,7 +29,9 @@ </intent-filter> </provider> - <service android:name=".MtpDocumentsService"/> + <service android:name=".MtpDocumentsService" + android:foregroundServiceType="dataSync"> + </service> <activity android:name=".ReceiverActivity" android:label="@string/downloads_app_label" diff --git a/tests/AndroidTest.xml b/tests/AndroidTest.xml index 83b287a..7f46b53 100644 --- a/tests/AndroidTest.xml +++ b/tests/AndroidTest.xml @@ -14,7 +14,7 @@ limitations under the License. --> <configuration description="Runs Tests for MtpService with the UI for output."> - <target_preparer class="com.android.tradefed.targetprep.TestAppInstallSetup"> + <target_preparer class="com.android.tradefed.targetprep.suite.SuiteApkInstaller"> <option name="test-file-name" value="MtpServiceTests.apk" /> </target_preparer> |