-
Notifications
You must be signed in to change notification settings - Fork 3.4k
[Android] Introduces API 34 emulators for subset of tests #4820
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 37 commits
dec3d69
0e0333b
bd7ac99
5c3363b
fed9621
5aabe34
2b9a352
a1173da
cbc3d6b
cae5a4c
72283db
166a77c
399780e
8d5d0e7
084d960
d2a59ac
a1422bf
bdd87a6
137a28b
bc0db5a
d04b466
a9cfe87
a32def1
4785148
7a8fc69
b02e15f
c6e5868
0c0065a
9dfe259
bfcc0df
7ee21ea
cc2957d
0026d0e
0bc3706
791dd78
c687491
d91007d
4c628c7
83afe66
89a968a
4430919
f39b0b0
cd977fe
70c7aeb
57117d8
844c8cb
3861779
a42b3e6
ea10dde
f4b839e
685f810
5272d12
a764265
c8883bc
3cfd2b3
106db42
7dab380
378c808
e3229a8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,7 +25,7 @@ platform_properties: | |
device_type: none | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_sdk", "version": "version:33v6"}, | ||
{"dependency": "android_sdk", "version": "version:34v1"}, | ||
{"dependency": "open_jdk", "version": "version:17"}, | ||
{"dependency": "curl", "version": "version:7.64.0"} | ||
] | ||
|
@@ -250,7 +250,7 @@ targets: | |
# web_benchmarks needs Chrome. | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"}, | ||
{"dependency": "android_virtual_device", "version": "34"}, | ||
{"dependency": "clang", "version": "git_revision:5d5aba78dbbee75508f01bcaa69aedb2ab79065a"}, | ||
{"dependency": "chrome_and_driver", "version": "version:114.0"} | ||
] | ||
|
@@ -267,7 +267,7 @@ targets: | |
# See comments on 'master' version above. | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"}, | ||
{"dependency": "android_virtual_device", "version": "34"}, | ||
{"dependency": "clang", "version": "git_revision:5d5aba78dbbee75508f01bcaa69aedb2ab79065a"}, | ||
{"dependency": "chrome_and_driver", "version": "version:114.0"} | ||
] | ||
|
@@ -306,7 +306,7 @@ targets: | |
recipe: packages/packages | ||
timeout: 60 | ||
properties: | ||
target_file: android_platform_tests.yaml | ||
target_file: android_platform_tests_api_33.yaml | ||
channel: master | ||
version_file: flutter_master.version | ||
package_sharding: "--shardIndex 0 --shardCount 6" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You'll need to changed the shard flags (the names of the tasks will be slightly confusing during the transition, but changing names is a huge pain with LUCI), so that each of the two partitions has their own shards, otherwise we may end up with a plugin assigned to a specific shard, but then excluded in that shard (since sharding is pre-exclusion, for slightly complicated reasons). So I believe the setup we need is something like:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The other option we could consider if we think we'll be in this state for a while is to bring up a new task or two for 33 tests, and leave the existing 6 shards as-is but with 34, so the names make more sense. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm going to be actively working on getting the tests failing on 34 working, but two of the failures have been really tricky, so could be a matter of months worst case. I'll start changing the shard flags but let me know if you think it makes more sense to add new tasks instead given that projection. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think on a potential timeline of months it's probably better to bring up 1-2 new shards for 33. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok hoping to be faster but I think that's probably safest. |
||
|
@@ -325,7 +325,7 @@ targets: | |
package_sharding: "--shardIndex 1 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_3 master | ||
|
@@ -338,14 +338,14 @@ targets: | |
package_sharding: "--shardIndex 2 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_4 master | ||
recipe: packages/packages | ||
timeout: 60 | ||
properties: | ||
target_file: android_platform_tests.yaml | ||
target_file: android_platform_tests_api_33.yaml | ||
channel: master | ||
version_file: flutter_master.version | ||
package_sharding: "--shardIndex 3 --shardCount 6" | ||
|
@@ -364,7 +364,7 @@ targets: | |
package_sharding: "--shardIndex 4 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_6 master | ||
|
@@ -377,7 +377,7 @@ targets: | |
package_sharding: "--shardIndex 5 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_1 stable | ||
|
@@ -391,7 +391,7 @@ targets: | |
package_sharding: "--shardIndex 0 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_2 stable | ||
|
@@ -405,7 +405,7 @@ targets: | |
package_sharding: "--shardIndex 1 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_3 stable | ||
|
@@ -419,7 +419,7 @@ targets: | |
package_sharding: "--shardIndex 2 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_4 stable | ||
|
@@ -433,7 +433,7 @@ targets: | |
package_sharding: "--shardIndex 3 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_5 stable | ||
|
@@ -447,7 +447,7 @@ targets: | |
package_sharding: "--shardIndex 4 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
- name: Linux_android android_platform_tests_shard_6 stable | ||
|
@@ -461,7 +461,7 @@ targets: | |
package_sharding: "--shardIndex 5 --shardCount 6" | ||
dependencies: >- | ||
[ | ||
{"dependency": "android_virtual_device", "version": "33"} | ||
{"dependency": "android_virtual_device", "version": "34"} | ||
] | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You'll need to add matching |
||
# Device versions of Android integration tests, run via FTL. | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# 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"] | ||
- name: build examples | ||
script: script/tool_runner.sh | ||
args: ["build-examples", "--apk"] | ||
- name: lint | ||
script: script/tool_runner.sh | ||
args: ["lint-android"] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since these tasks aren't being passed either of the include/exclude flags, they will all run twice: once on the 34 shards and once on the 33 shards, even though there's no difference. We should either pass the flags to everything, to keep all the tasks for a given plugin together, and running only in one place, or we should remove these two tasks from the 33 version, so all builds and lints run on the 34 shards. I would vote for the former, for consistency, but either should work. |
||
# 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", "--exclude=script/configs/exclude_native_unit_android.yaml"] | ||
- name: native integration tests | ||
script: script/tool_runner.sh | ||
args: ["native-test", "--android", "--no-unit"] | ||
- name: drive examples | ||
script: script/tool_runner.sh | ||
args: ["drive-examples", "--android", "--exclude=script/configs/exclude_integration_android.yaml,script/configs/exclude_integration_android_emulator.yaml", "--filter-packages-to=script/configs/still_requires_api_33_avd.yaml"] | ||
camsim99 marked this conversation as resolved.
Show resolved
Hide resolved
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -99,7 +99,7 @@ public void appShortcutLaunchActivityAfterStarting() { | |
.filter(s -> s.getId().equals(firstShortcut.getId())) | ||
.findFirst() | ||
.get(); | ||
Intent dynamicShortcutIntent = dynamicShortcut.getIntent(); | ||
Intent dynamicShortcutIntent = dynamicShortcut.getIntent().addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This line is too long and needs to be formatted. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Removed this fix attempt and excluded |
||
AtomicReference<QuickActionsTestActivity> initialActivity = new AtomicReference<>(); | ||
scenario.onActivity(initialActivity::set); | ||
String appReadySentinel = " has launched"; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Running the tests of these packages on an AVD with Android 34 causes failures. | ||
- file_selector | ||
- path_provider |
Uh oh!
There was an error while loading. Please reload this page.