Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1b922d56 authored by Ryan Mitchell's avatar Ryan Mitchell Committed by Android (Google) Code Review
Browse files

Merge "Begin moving FrameworkResourceLoaderTest to cts" into rvc-dev

parents 589c5c55 199b09a1
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
{
  "presubmit": [
    {
      "name": "FrameworksResourceLoaderTests"
      "name": "CtsResourcesLoaderTests"
    }
  ]
}
+0 −64
Original line number Diff line number Diff line
//
// Copyright (C) 2019 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.
//

android_test {
    name: "FrameworksResourceLoaderTests",
    srcs: [
        "src/**/*.kt"
    ],
    libs: [
        "android.test.runner",
        "android.test.base"
    ],
    static_libs: [
        "FrameworksResourceLoaderTests_Providers",
        "androidx.test.espresso.core",
        "androidx.test.ext.junit",
        "androidx.test.runner",
        "androidx.test.rules",
        "mockito-target-minus-junit4",
        "truth-prebuilt"
    ],
    resource_dirs: ["res", "resources/provider_stable/res"],
    platform_apis: true,
    test_suites: ["device-tests"],
    aaptflags: ["-0 .txt"],
    data: [
        ":FrameworksResourceLoaderTests_ProviderOne_Split",
        ":FrameworksResourceLoaderTests_ProviderTwo_Split",
        ":FrameworksResourceLoaderTests_ProviderThree_Split",
        ":FrameworksResourceLoaderTests_ProviderFour_Split"
    ]
}

java_genrule {
    name: "FrameworksResourceLoaderTests_Providers",
    tools: ["soong_zip"],
    srcs : [
        ":FrameworksResourceLoaderTests_ProviderOne",
        ":FrameworksResourceLoaderTests_ProviderOne_ARSC",
        ":FrameworksResourceLoaderTests_ProviderTwo",
        ":FrameworksResourceLoaderTests_ProviderTwo_ARSC",
        ":FrameworksResourceLoaderTests_ProviderThree",
        ":FrameworksResourceLoaderTests_ProviderThree_ARSC",
        ":FrameworksResourceLoaderTests_ProviderFour",
        ":FrameworksResourceLoaderTests_ProviderFour_ARSC"
    ],
    out: ["FrameworksResourceLoaderTests_Providers.jar"],
    cmd: "mkdir -p $(genDir)/assets/ && cp $(in) $(genDir)/assets/ && " +
         "$(location soong_zip) -o $(out) " +
         "-L 0 -C $(genDir) -D $(genDir)/assets/"
}
 No newline at end of file
+0 −42
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2019 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
  -->

<!-- Split loading is tested separately, so this must be marked isolated -->
<manifest
    xmlns:android="http://schemas.android.com/apk/res/android"
    package="android.content.res.loader.test"
    android:isolatedSplits="true"
    >

    <uses-sdk android:minSdkVersion="29"/>

    <application>
        <uses-library android:name="android.test.runner"/>

        <activity
            android:name=".TestActivity"
            android:configChanges="orientation"
            />
    </application>

    <instrumentation
        android:name="androidx.test.runner.AndroidJUnitRunner"
        android:label="ResourceLoaderTests"
        android:targetPackage="android.content.res.loader.test"
        />

</manifest>
+0 −31
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2019 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.
  -->

<configuration description="Test module config for ResourceLoaderTests">
    <option name="test-tag" value="ResourceLoaderTests" />

    <target_preparer class="com.android.tradefed.targetprep.TestAppInstallSetup">
        <option name="cleanup-apks" value="true" />
        <!-- The following value cannot be multi-line as whitespace is parsed by the installer -->
        <option name="split-apk-file-names"
            value="FrameworksResourceLoaderTests.apk,FrameworksResourceLoaderTests_ProviderOne_Split.apk,FrameworksResourceLoaderTests_ProviderTwo_Split.apk,FrameworksResourceLoaderTests_ProviderThree_Split.apk,FrameworksResourceLoaderTests_ProviderFour_Split.apk" />
    </target_preparer>

    <test class="com.android.tradefed.testtype.AndroidJUnitTest">
        <option name="package" value="android.content.res.loader.test" />
    </test>
</configuration>
+0 −1
Original line number Diff line number Diff line
In assets directory
 No newline at end of file
Loading