diff --git a/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/BUILD b/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/BUILD index 4dbc185a5..3d8c73060 100644 --- a/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/BUILD +++ b/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/BUILD @@ -66,24 +66,3 @@ axt_android_local_test( "@maven//:org_hamcrest_hamcrest_library", ], ) - -axt_android_library_test( - name = "RuntimePermissionsIntegrationTest", - srcs = ["RuntimePermissionsIntegrationTest.java"], - args = [ - "--grant_runtime_permissions=false", - "--install_test_services", - "--experimental_test_driver=LOCAL_TEST_DRIVER_ORCHESTRATOR_V1", - ], - custom_package = "androidx.test.orchestrator.tests", - device_list = devices( - apis(min_api = 24), - ), - deps = [ - "//ext/junit", - "//runner/android_junit_runner", - "@maven//:junit_junit", - "@maven//:org_hamcrest_hamcrest_core", - "@maven//:org_hamcrest_hamcrest_library", - ], -) diff --git a/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/RuntimePermissionsIntegrationTest.java b/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/RuntimePermissionsIntegrationTest.java deleted file mode 100644 index f0b3d2632..000000000 --- a/runner/android_test_orchestrator/javatests/androidx/test/orchestrator/RuntimePermissionsIntegrationTest.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright (C) 2017 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 androidx.test.orchestrator; - -import static androidx.test.platform.app.InstrumentationRegistry.getInstrumentation; -import static org.hamcrest.MatcherAssert.assertThat; -import static org.hamcrest.Matchers.equalTo; - -import android.Manifest.permission; -import android.content.pm.PackageManager; -import androidx.test.ext.junit.runners.AndroidJUnit4; -import androidx.test.filters.MediumTest; -import androidx.test.filters.SdkSuppress; -import org.junit.Test; -import org.junit.runner.RunWith; - -/** Integration tests for {@link AndroidTestOrchestrator} runtime permission handling */ -@RunWith(AndroidJUnit4.class) -@MediumTest -public class RuntimePermissionsIntegrationTest { - - private static final String ORCHESTRATOR_PACKAGE = "androidx.test.orchestrator"; - - @Test - @SdkSuppress(minSdkVersion = 24) - public void verifyEssentialRuntimePermissionsAreGranted() { - assertThat( - getInstrumentation() - .getContext() - .getPackageManager() - .checkPermission(permission.READ_EXTERNAL_STORAGE, ORCHESTRATOR_PACKAGE), - equalTo(PackageManager.PERMISSION_GRANTED)); - assertThat( - getInstrumentation() - .getContext() - .getPackageManager() - .checkPermission(permission.WRITE_EXTERNAL_STORAGE, ORCHESTRATOR_PACKAGE), - equalTo(PackageManager.PERMISSION_GRANTED)); - } -}