Commit 581b929b authored by Ian Hickson's avatar Ian Hickson Committed by GitHub

Actually fix the memory_nav benchmark (#8041)

parent 473b67ef
......@@ -18,16 +18,25 @@ void main() {
});
test('navigation', () async {
Completer<Null> completer = new Completer<Null>();
bool scroll = true;
SerializableFinder menuItem = find.text('Text fields');
await driver.scrollIntoView(menuItem, alignment: 0.5);
await new Future<Null>.delayed(kWaitBetweenActions);
for (int i = 0; i < 15; i++) {
await driver.tap(menuItem);
driver.waitFor(menuItem).then<Null>((Null value) async {
scroll = false;
await new Future<Null>.delayed(kWaitBetweenActions);
await driver.tap(find.byTooltip('Back'));
for (int i = 0; i < 15; i++) {
await driver.tap(menuItem);
await new Future<Null>.delayed(kWaitBetweenActions);
await driver.tap(find.byTooltip('Back'));
await new Future<Null>.delayed(kWaitBetweenActions);
}
completer.complete();
});
while (scroll) {
await driver.scroll(find.text('Flutter Gallery'), 0.0, -500.0, const Duration(milliseconds: 80));
await new Future<Null>.delayed(kWaitBetweenActions);
}
await completer.future;
}, timeout: new Timeout(new Duration(minutes: 1)));
});
}
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