Unverified Commit 295eeaf1 authored by Jonah Williams's avatar Jonah Williams Committed by GitHub

[devicelab] retain first frame data in certain integration tests. (#143419)

Part of https://github.com/flutter/flutter/issues/143404

We currently drop the first N frames of all benchmarks. For the app based benchmarks (not microbenchmarks) this is harmful as we miss first time initialization costs in our CI.

Still need to do this with flutter/gallery, but that lives in a different repo.
parent e2567f49
...@@ -44,7 +44,7 @@ void main() { ...@@ -44,7 +44,7 @@ void main() {
await driver.scroll(list, 0.0, 300.0, const Duration(milliseconds: 300)); await driver.scroll(list, 0.0, 300.0, const Duration(milliseconds: 300));
await Future<void>.delayed(const Duration(milliseconds: 500)); await Future<void>.delayed(const Duration(milliseconds: 500));
} }
}); }, retainPriorEvents: true);
final TimelineSummary summary = TimelineSummary.summarize(timeline); final TimelineSummary summary = TimelineSummary.summarize(timeline);
await summary.writeTimelineToFile(summaryName, pretty: true); await summary.writeTimelineToFile(summaryName, pretty: true);
......
...@@ -46,7 +46,7 @@ void main() { ...@@ -46,7 +46,7 @@ void main() {
await driver.scroll(list, 0.0, 300.0, const Duration(milliseconds: 300)); await driver.scroll(list, 0.0, 300.0, const Duration(milliseconds: 300));
await Future<void>.delayed(const Duration(milliseconds: 500)); await Future<void>.delayed(const Duration(milliseconds: 500));
} }
}); }, retainPriorEvents: true);
final TimelineSummary summary = TimelineSummary.summarize(timeline); final TimelineSummary summary = TimelineSummary.summarize(timeline);
await summary.writeTimelineToFile(summaryName, pretty: true); await summary.writeTimelineToFile(summaryName, pretty: true);
......
...@@ -30,7 +30,7 @@ void main() { ...@@ -30,7 +30,7 @@ void main() {
await driver.tap(find.byTooltip('Back')); await driver.tap(find.byTooltip('Back'));
await Future<void>.delayed(const Duration(milliseconds: 500)); await Future<void>.delayed(const Duration(milliseconds: 500));
} }
}); }, retainPriorEvents: true);
final TimelineSummary summary = TimelineSummary.summarize(timeline); final TimelineSummary summary = TimelineSummary.summarize(timeline);
await summary.writeTimelineToFile('page_transition_perf', pretty: true); await summary.writeTimelineToFile('page_transition_perf', pretty: true);
......
...@@ -25,9 +25,6 @@ void main() { ...@@ -25,9 +25,6 @@ void main() {
final SerializableFinder demoList = find.byValueKey('GalleryDemoList'); final SerializableFinder demoList = find.byValueKey('GalleryDemoList');
// TODO(eseidel): These are very artificial scrolls, we should use better
// https://github.com/flutter/flutter/issues/3316
// Scroll down
for (int i = 0; i < 5; i++) { for (int i = 0; i < 5; i++) {
await driver.scroll(demoList, 0.0, -300.0, const Duration(milliseconds: 300)); await driver.scroll(demoList, 0.0, -300.0, const Duration(milliseconds: 300));
await Future<void>.delayed(const Duration(milliseconds: 500)); await Future<void>.delayed(const Duration(milliseconds: 500));
...@@ -38,7 +35,7 @@ void main() { ...@@ -38,7 +35,7 @@ void main() {
await driver.scroll(demoList, 0.0, 300.0, const Duration(milliseconds: 300)); await driver.scroll(demoList, 0.0, 300.0, const Duration(milliseconds: 300));
await Future<void>.delayed(const Duration(milliseconds: 500)); await Future<void>.delayed(const Duration(milliseconds: 500));
} }
}); }, retainPriorEvents: true);
final TimelineSummary summary = TimelineSummary.summarize(timeline); final TimelineSummary summary = TimelineSummary.summarize(timeline);
await summary.writeTimelineToFile('home_scroll_perf', pretty: true); await summary.writeTimelineToFile('home_scroll_perf', pretty: true);
......
...@@ -212,6 +212,7 @@ void main([List<String> args = const <String>[]]) { ...@@ -212,6 +212,7 @@ void main([List<String> args = const <String>[]]) {
TimelineStream.embedder, TimelineStream.embedder,
TimelineStream.gc, TimelineStream.gc,
], ],
retainPriorEvents: true,
); );
// Save the duration (in microseconds) of the first timeline Frame event // Save the duration (in microseconds) of the first timeline Frame event
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment