From 21c2ebb39c0732b8c4ae2d68f25b96a895be915f Mon Sep 17 00:00:00 2001 From: Camille Simon <43054281+camsim99@users.noreply.github.com> Date: Tue, 26 Sep 2023 18:58:22 +0000 Subject: [PATCH] [Android] Add new tasks for subset of tests to run API 33 (#4974) Adds new tasks to create shards to run a subset of Android platform tests on API 33 AVD tests when the update to run tests on AVDs with API 34 lands due to test failures on a subset of plugins. Prequel PR to https://github.com/flutter/packages/pull/4820. --- .ci.yaml | 56 +++++++++++++++++++ .../android_platform_tests_api_33_avd.yaml | 30 ++++++++++ script/configs/still_requires_api_33_avd.yaml | 4 ++ 3 files changed, 90 insertions(+) create mode 100644 .ci/targets/android_platform_tests_api_33_avd.yaml create mode 100644 script/configs/still_requires_api_33_avd.yaml diff --git a/.ci.yaml b/.ci.yaml index c5fb8963261f..868d82d387dc 100644 --- a/.ci.yaml +++ b/.ci.yaml @@ -380,6 +380,34 @@ targets: {"dependency": "android_virtual_device", "version": "33"} ] + - name: Linux_android android_platform_tests_api_33_shard_1 master + recipe: packages/packages + timeout: 60 + bringup: true + properties: + target_file: android_platform_tests_api_33.yaml + channel: master + version_file: flutter_master.version + package_sharding: "--shardIndex 0 --shardCount 2" + dependencies: >- + [ + {"dependency": "android_virtual_device", "version": "33"} + ] + + - name: Linux_android android_platform_tests_api_33_shard_2 master + recipe: packages/packages + timeout: 60 + bringup: true + properties: + target_file: android_platform_tests_api_33.yaml + channel: master + version_file: flutter_master.version + package_sharding: "--shardIndex 1 --shardCount 2" + dependencies: >- + [ + {"dependency": "android_virtual_device", "version": "33"} + ] + - name: Linux_android android_platform_tests_shard_1 stable recipe: packages/packages presubmit: false @@ -464,6 +492,34 @@ targets: {"dependency": "android_virtual_device", "version": "33"} ] + - name: Linux_android android_platform_tests_api_33_shard_1 stable + recipe: packages/packages + timeout: 60 + bringup: true + properties: + target_file: android_platform_tests_api_33.yaml + channel: master + version_file: flutter_stable.version + package_sharding: "--shardIndex 0 --shardCount 2" + dependencies: >- + [ + {"dependency": "android_virtual_device", "version": "33"} + ] + + - name: Linux_android android_platform_tests_api_33_shard_2 stable + recipe: packages/packages + timeout: 60 + bringup: true + properties: + target_file: android_platform_tests_api_33.yaml + channel: master + version_file: flutter_stable.version + package_sharding: "--shardIndex 1 --shardCount 2" + dependencies: >- + [ + {"dependency": "android_virtual_device", "version": "33"} + ] + # Device versions of Android integration tests, run via FTL. # TODO(stuartmorgan): Revisit whether physical device tests are redundant once # we have more data about emulator tests; see diff --git a/.ci/targets/android_platform_tests_api_33_avd.yaml b/.ci/targets/android_platform_tests_api_33_avd.yaml new file mode 100644 index 000000000000..cbec7c79127b --- /dev/null +++ b/.ci/targets/android_platform_tests_api_33_avd.yaml @@ -0,0 +1,30 @@ +# Same as android_platform_tests.yaml with only packages currently requiring +# Android 33 due to test failures caused by running on Android 34 AVDs. +tasks: + - name: prepare tool + script: .ci/scripts/prepare_tool.sh + infra_step: true # Note infra steps failing prevents "always" from running. + - name: download Dart and Android deps + script: script/tool_runner.sh + infra_step: true + args: ["fetch-deps", "--android", "--supporting-target-platforms-only", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] + - name: build examples + script: script/tool_runner.sh + args: ["build-examples", "--apk", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] + - name: lint + script: script/tool_runner.sh + args: ["lint-android", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] + # Native unit and native integration are split into two steps to allow for + # different exclusions. + # TODO(stuartmorgan): Eliminate the native unit test exclusion, and combine + # these steps. + - name: native unit tests + script: script/tool_runner.sh + args: ["native-test", "--android", "--no-integration", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] + - name: native integration tests + script: script/tool_runner.sh + args: ["native-test", "--android", "--no-unit", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] + - name: drive examples + script: script/tool_runner.sh + args: ["drive-examples", "--android", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] + diff --git a/script/configs/still_requires_api_33_avd.yaml b/script/configs/still_requires_api_33_avd.yaml new file mode 100644 index 000000000000..87f711c25b77 --- /dev/null +++ b/script/configs/still_requires_api_33_avd.yaml @@ -0,0 +1,4 @@ +# Running the somes tests from these packages on an AVD with Android 34 causes failures. +- file_selector +- quick_actions +- webview_flutter