Skip to content

Commit

Permalink
[Android] Update integration test AVD dependency to use Android 35 em…
Browse files Browse the repository at this point in the history
…ulators (flutter#54186)

Updates AVD dependency to use [latest available AVD dependency](https://chrome-infra-packages.appspot.com/p/chromium/tools/android/avd/linux-amd64/+/I7SIawD0okHpiEe8fKvI5NQrMEWDibsvOduVbbK5pDEC) (older at the time of publishing but the same I set in the framework -- flutter/flutter#152498) so that engine integration tests run on emulators running Android 35, the current latest version of Android.

Does not change dependency of one test that is intended to run on Android 28.

Also adds tasks to run the same emulator tests on those running Android 34 since Android 35 emulators seem to crash off and on.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
  • Loading branch information
camsim99 authored Aug 12, 2024
1 parent 8bc8111 commit b877e89
Show file tree
Hide file tree
Showing 5 changed files with 313 additions and 22 deletions.
47 changes: 44 additions & 3 deletions .ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,6 @@ platform_properties:
device_type: none
os: Windows-10

# The current android emulator config names can be found here:
# https://chromium.googlesource.com/chromium/src.git/+/HEAD/tools/android/avd/proto
# You may use those names for the android_virtual_device version.
targets:
- name: Linux local_engine_builds
enabled_branches:
Expand All @@ -57,6 +54,7 @@ targets:
config_name: local_engine

- name: Linux linux_android_emulator_tests
bringup: true
enabled_branches:
- main
recipe: engine_v2/engine_v2
Expand All @@ -76,7 +74,29 @@ targets:
- testing/scenario_app/**
- testing/skia_gold_client/**

- name: Linux linux_android_emulator_tests_34
bringup: true
enabled_branches:
- main
recipe: engine_v2/engine_v2
properties:
config_name: linux_android_emulator_34
dependencies: >-
[
{"dependency": "goldctl", "version": "git_revision:720a542f6fe4f92922c3b8f0fdcc4d2ac6bb83cd"}
]
timeout: 90
runIf:
- .ci.yaml
- ci/builders/linux_android_emulator.json
- DEPS
- lib/ui/**
- shell/platform/android/**
- testing/scenario_app/**
- testing/skia_gold_client/**

- name: Linux linux_android_emulator_skia_tests
bringup: true
enabled_branches:
- main
recipe: engine_v2/engine_v2
Expand All @@ -96,6 +116,27 @@ targets:
- testing/scenario_app/**
- testing/skia_gold_client/**

- name: Linux linux_android_emulator_skia_tests_34
bringup: true
enabled_branches:
- main
recipe: engine_v2/engine_v2
properties:
config_name: linux_android_emulator_skia_34
dependencies: >-
[
{"dependency": "goldctl", "version": "git_revision:720a542f6fe4f92922c3b8f0fdcc4d2ac6bb83cd"}
]
timeout: 90
runIf:
- .ci.yaml
- ci/builders/linux_android_emulator.json
- DEPS
- lib/ui/**
- shell/platform/android/**
- testing/scenario_app/**
- testing/skia_gold_client/**

- name: Linux builder_cache
enabled_branches:
- main
Expand Down
28 changes: 14 additions & 14 deletions ci/builders/linux_android_emulator.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,22 +42,22 @@
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_34_google_apis_x64.textpb"
"version": "android_35_google_apis_x64.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8759428741582061553"
"version": "build_id:8740267484269553649"
}
],
"contexts": [
"android_virtual_device"
],
"script": "flutter/testing/run_tests.py",
"parameters": [
"--android-variant",
"ci/android_emulator_debug_x64",
"--type",
"android"
"--android-variant",
"ci/android_emulator_debug_x64",
"--type",
"android"
]
},
{
Expand All @@ -74,11 +74,11 @@
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_34_google_apis_x64.textpb"
"version": "android_35_google_apis_x64.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8759428741582061553"
"version": "build_id:8740267484269553649"
}
],
"contexts": [
Expand Down Expand Up @@ -139,21 +139,21 @@
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8759428741582061553"
"version": "build_id:8740267484269553649"
}
],
"contexts": [
"android_virtual_device"
],
"script": "flutter/testing/run_tests.py",
"parameters": [
"--android-variant",
"ci/android_emulator_debug_x86",
"--type",
"android"
"--android-variant",
"ci/android_emulator_debug_x86",
"--type",
"android"
]
}
]
}
]
}
}
159 changes: 159 additions & 0 deletions ci/builders/linux_android_emulator_34.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
{
"builds": [
{
"drone_dimensions": [
"device_type=none",
"os=Linux",
"kvm=1",
"cores=8"
],
"gclient_variables": {
"use_rbe": true
},
"gn": [
"--android",
"--android-cpu=x64",
"--no-lto",
"--rbe",
"--no-goma",
"--target-dir",
"ci/android_emulator_debug_x64"
],
"dependencies": [
{
"dependency": "goldctl",
"version": "git_revision:720a542f6fe4f92922c3b8f0fdcc4d2ac6bb83cd"
}
],
"name": "ci/android_emulator_debug_x64",
"description": "Build for debug mode x64 Android emulator tests, and Impeller scenario app tests.",
"ninja": {
"config": "ci/android_emulator_debug_x64",
"targets": [
"flutter/impeller/toolkit/android:unittests",
"flutter/shell/platform/android:flutter_shell_native_unittests",
"flutter/testing/scenario_app"
]
},
"tests": [
{
"language": "python3",
"name": "Android Unit Tests",
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_34_google_apis_x64.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8740267484269553649"
}
],
"contexts": [
"android_virtual_device"
],
"script": "flutter/testing/run_tests.py",
"parameters": [
"--android-variant",
"ci/android_emulator_debug_x64",
"--type",
"android"
]
},
{
"language": "dart",
"name": "skia_gold_client/e2e_test",
"script": "flutter/testing/skia_gold_client/tool/e2e_test.dart",
"max_attempts": 1
},
{
"language": "dart",
"name": "Android Scenario App Integration Tests (Impeller/Vulkan)",
"test_timeout_secs": 900,
"max_attempts": 2,
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_34_google_apis_x64.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8740267484269553649"
}
],
"contexts": [
"android_virtual_device"
],
"script": "flutter/testing/scenario_app/bin/run_android_tests.dart",
"parameters": [
"--out-dir=../out/ci/android_emulator_debug_x64",
"--enable-impeller",
"--impeller-backend=vulkan"
]
}
]
},
{
"drone_dimensions": [
"device_type=none",
"os=Linux",
"kvm=1",
"cores=8"
],
"gclient_variables": {
"use_rbe": true
},
"gn": [
"--android",
"--android-cpu=x86",
"--no-lto",
"--rbe",
"--no-goma",
"--target-dir",
"ci/android_emulator_debug_x86"
],
"dependencies": [
{
"dependency": "goldctl",
"version": "git_revision:720a542f6fe4f92922c3b8f0fdcc4d2ac6bb83cd"
}
],
"name": "ci/android_emulator_debug_x86",
"description": "Build for debug mode x86 Android emulator tests.",
"ninja": {
"config": "ci/android_emulator_debug_x86",
"targets": [
"flutter/impeller/toolkit/android:unittests",
"flutter/shell/platform/android:flutter_shell_native_unittests",
"flutter/testing/scenario_app"
]
},
"tests": [
{
"language": "python3",
"name": "Android Unit Tests (API 28)",
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_28_google_apis_x86.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8740267484269553649"
}
],
"contexts": [
"android_virtual_device"
],
"script": "flutter/testing/run_tests.py",
"parameters": [
"--android-variant",
"ci/android_emulator_debug_x86",
"--type",
"android"
]
}
]
}
]
}
10 changes: 5 additions & 5 deletions ci/builders/linux_android_emulator_skia.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_34_google_apis_x64.textpb"
"version": "android_35_google_apis_x64.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8759428741582061553"
"version": "build_id:8740267484269553649"
}
],
"contexts": [
Expand All @@ -68,11 +68,11 @@
"test_dependencies": [
{
"dependency": "android_virtual_device",
"version": "android_34_google_apis_x64.textpb"
"version": "android_35_google_apis_x64.textpb"
},
{
"dependency": "avd_cipd_version",
"version": "build_id:8759428741582061553"
"version": "build_id:8740267484269553649"
}
],
"contexts": [
Expand All @@ -88,4 +88,4 @@
]
}
]
}
}
Loading

0 comments on commit b877e89

Please sign in to comment.