migrate macrobenchmark/multi_widget_construction test to e2e (#62539)
diff --git a/dev/benchmarks/macrobenchmarks/README.md b/dev/benchmarks/macrobenchmarks/README.md
index 5d11345..5296cca 100644
--- a/dev/benchmarks/macrobenchmarks/README.md
+++ b/dev/benchmarks/macrobenchmarks/README.md
@@ -45,6 +45,8 @@
- `animated_placeholder_perf`
- `backdrop_filter_perf`
+- `color_filter_and_fade_perf`
+- `cubic_bezier_perf`
- `cull_opacity_perf`
- `fading_child_animation_perf`
- `imagefiltered_transform_animation_perf`
@@ -53,7 +55,6 @@
- `post_backdrop_filter_perf`
- `simple_animation_perf`
- `textfield_perf`
-- `cubic_bezier_perf`
### E2E benchmarks
@@ -63,6 +64,7 @@
host machine. The following tests are E2E:
- `cull_opacity_perf.dart`
+- `multi_widget_construction_perf`
These tests should be run by:
diff --git a/dev/benchmarks/macrobenchmarks/test/multi_widget_construction_perf_e2e.dart b/dev/benchmarks/macrobenchmarks/test/multi_widget_construction_perf_e2e.dart
new file mode 100644
index 0000000..c5991e2
--- /dev/null
+++ b/dev/benchmarks/macrobenchmarks/test/multi_widget_construction_perf_e2e.dart
@@ -0,0 +1,17 @@
+// Copyright 2014 The Flutter Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+import 'package:macrobenchmarks/common.dart';
+
+import 'util.dart';
+
+void main() {
+ macroPerfTestE2E(
+ 'multi_widget_construction_perf',
+ kMultiWidgetConstructionRouteName,
+ pageDelay: const Duration(seconds: 1),
+ duration: const Duration(seconds: 10),
+ timeout: const Duration(seconds: 45),
+ );
+}
diff --git a/dev/devicelab/bin/tasks/multi_widget_construction_perf__e2e_summary.dart b/dev/devicelab/bin/tasks/multi_widget_construction_perf__e2e_summary.dart
new file mode 100644
index 0000000..2dd5f61
--- /dev/null
+++ b/dev/devicelab/bin/tasks/multi_widget_construction_perf__e2e_summary.dart
@@ -0,0 +1,14 @@
+// Copyright 2014 The Flutter Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+import 'dart:async';
+
+import 'package:flutter_devicelab/tasks/perf_tests.dart';
+import 'package:flutter_devicelab/framework/adb.dart';
+import 'package:flutter_devicelab/framework/framework.dart';
+
+Future<void> main() async {
+ deviceOperatingSystem = DeviceOperatingSystem.android;
+ await task(createsMultiWidgetConstructPerfE2ETest());
+}
diff --git a/dev/devicelab/lib/tasks/perf_tests.dart b/dev/devicelab/lib/tasks/perf_tests.dart
index 06b245a..4c1301c 100644
--- a/dev/devicelab/lib/tasks/perf_tests.dart
+++ b/dev/devicelab/lib/tasks/perf_tests.dart
@@ -269,6 +269,13 @@
).run;
}
+TaskFunction createsMultiWidgetConstructPerfE2ETest() {
+ return E2EPerfTest(
+ '${flutterDirectory.path}/dev/benchmarks/macrobenchmarks',
+ 'test/multi_widget_construction_perf_e2e.dart',
+ ).run;
+}
+
TaskFunction createFramePolicyIntegrationTest() {
final String testDirectory =
'${flutterDirectory.path}/dev/benchmarks/macrobenchmarks';
diff --git a/dev/devicelab/manifest.yaml b/dev/devicelab/manifest.yaml
index c8f7944..0a42a8b 100644
--- a/dev/devicelab/manifest.yaml
+++ b/dev/devicelab/manifest.yaml
@@ -172,6 +172,13 @@
stage: devicelab
required_agent_capabilities: ["linux/android"]
+ multi_widget_construction_perf__e2e_summary:
+ description: >
+ Measures the runtime performance of constructing and destructing widgets on Android.
+ stage: devicelab
+ required_agent_capabilities: ["linux/android"]
+ flaky: true
+
frame_policy_delay_test_android:
description: >
Tests the effect of LiveTestWidgetsFlutterBindingFramePolicy.benchmarkLive