Unverified Commit 11025e4a authored by gaaclarke's avatar gaaclarke Committed by GitHub

Sped up the time to find macrobenchmarks. (#131959)

This reduce the execution time of macrobenchmarks driver tests.

I tried to find the exact size to scroll the screen but I couldn't find a way to do that with driver tests.
parent 53082f65
......@@ -23,7 +23,11 @@ Future<void> runDriverTestForRoute(String routeName, DriverTestCallBack body) as
expect(scrollable, isNotNull);
final SerializableFinder button = find.byValueKey(routeName);
expect(button, isNotNull);
await driver.scrollUntilVisible(scrollable, button, dyScroll: -100.0);
// -320 comes from the logical pixels for a full screen scroll for the
// smallest reference device, iPhone 4, whose physical screen dimensions are
// 960px × 640px.
const double dyScroll = -320.0;
await driver.scrollUntilVisible(scrollable, button, dyScroll: dyScroll);
await driver.tap(button);
await body(driver);
......
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