Loading services/robotests/Android.bp +4 −0 Original line number Diff line number Diff line Loading @@ -57,9 +57,13 @@ android_robolectric_test { ], static_libs: [ "androidx.test.ext.truth", "Settings-robo-testutils", "SettingsLib-robo-testutils", ], instrumentation_for: "FrameworksServicesLib", upstream: true, } filegroup { Loading services/robotests/backup/Android.bp +4 −0 Original line number Diff line number Diff line Loading @@ -56,6 +56,8 @@ android_robolectric_test { // Include the testing libraries libs: [ "mockito-robolectric-prebuilt", "Settings-robo-testutils", "SettingsLib-robo-testutils", "platform-test-annotations", "testng", "truth", Loading @@ -63,4 +65,6 @@ android_robolectric_test { instrumentation_for: "BackupFrameworksServicesLib", upstream: true, } services/robotests/backup/config/robolectric.properties +3 −1 Original line number Diff line number Diff line sdk=NEWEST_SDK looperMode=LEGACY shadows=com.android.server.testing.shadows.FrameworkShadowLooper services/robotests/backup/src/com/android/server/backup/fullbackup/AppMetadataBackupWriterTest.java +1 −0 Original line number Diff line number Diff line Loading @@ -57,6 +57,7 @@ import java.nio.file.attribute.FileTime; ShadowBackupDataOutput.class, ShadowEnvironment.class, ShadowFullBackup.class, ShadowSigningInfo.class, }) public class AppMetadataBackupWriterTest { private static final String TEST_PACKAGE = "com.test.package"; Loading services/robotests/backup/src/com/android/server/backup/fullbackup/ShadowSigningInfo.java 0 → 100644 +27 −0 Original line number Diff line number Diff line /* * Copyright (C) 2018 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.server.backup.fullbackup; import static android.os.Build.VERSION_CODES.P; import android.content.pm.SigningInfo; import org.robolectric.annotation.Implements; @Implements(value = SigningInfo.class, minSdk = P) public class ShadowSigningInfo { } Loading
services/robotests/Android.bp +4 −0 Original line number Diff line number Diff line Loading @@ -57,9 +57,13 @@ android_robolectric_test { ], static_libs: [ "androidx.test.ext.truth", "Settings-robo-testutils", "SettingsLib-robo-testutils", ], instrumentation_for: "FrameworksServicesLib", upstream: true, } filegroup { Loading
services/robotests/backup/Android.bp +4 −0 Original line number Diff line number Diff line Loading @@ -56,6 +56,8 @@ android_robolectric_test { // Include the testing libraries libs: [ "mockito-robolectric-prebuilt", "Settings-robo-testutils", "SettingsLib-robo-testutils", "platform-test-annotations", "testng", "truth", Loading @@ -63,4 +65,6 @@ android_robolectric_test { instrumentation_for: "BackupFrameworksServicesLib", upstream: true, }
services/robotests/backup/config/robolectric.properties +3 −1 Original line number Diff line number Diff line sdk=NEWEST_SDK looperMode=LEGACY shadows=com.android.server.testing.shadows.FrameworkShadowLooper
services/robotests/backup/src/com/android/server/backup/fullbackup/AppMetadataBackupWriterTest.java +1 −0 Original line number Diff line number Diff line Loading @@ -57,6 +57,7 @@ import java.nio.file.attribute.FileTime; ShadowBackupDataOutput.class, ShadowEnvironment.class, ShadowFullBackup.class, ShadowSigningInfo.class, }) public class AppMetadataBackupWriterTest { private static final String TEST_PACKAGE = "com.test.package"; Loading
services/robotests/backup/src/com/android/server/backup/fullbackup/ShadowSigningInfo.java 0 → 100644 +27 −0 Original line number Diff line number Diff line /* * Copyright (C) 2018 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.server.backup.fullbackup; import static android.os.Build.VERSION_CODES.P; import android.content.pm.SigningInfo; import org.robolectric.annotation.Implements; @Implements(value = SigningInfo.class, minSdk = P) public class ShadowSigningInfo { }