Revert "Remove per-test timeouts from integration tests (#85098)" (#85133)

This reverts commit b96c3c22ce.
This commit is contained in:
Dan Field
2021-06-23 08:17:27 -07:00
committed by GitHub
parent b96c3c22ce
commit 69f2f8a18b
22 changed files with 35 additions and 18 deletions

View File

@@ -59,6 +59,7 @@ Future<void> main() async {
await driver.tap(tapWindow);
final String windowClickCount = await driver.getText(
find.byValueKey('WindowClickCount'),
timeout: const Duration(seconds: 5),
);
expect(windowClickCount, 'Click count: 1');
});

View File

@@ -25,7 +25,7 @@ void main() {
if (status != 'complete') {
fail('Failed at step $step with status $status');
}
});
}, timeout: const Timeout(Duration(minutes: 1)));
tearDownAll(() async {
driver.close();

View File

@@ -48,6 +48,7 @@ void main([List<String> args = const <String>[]]) {
..removeAll(kProfiledDemos);
await runDemos(unprofiledDemos.toList(), tester);
},
timeout: const Timeout(Duration(minutes: 5)),
semanticsEnabled: withSemantics,
);
});

View File

@@ -5,6 +5,7 @@
import 'package:integration_test/integration_test_driver.dart' as driver;
Future<void> main() => driver.integrationDriver(
timeout: const Duration(minutes: 5),
responseDataCallback: (Map<String, dynamic>? data) async {
await driver.writeResponseData(
data!['performance'] as Map<String, dynamic>,

View File

@@ -130,6 +130,7 @@ Future<void> runDemos(List<String> demos, FlutterDriver driver) async {
await driver.scrollUntilVisible(demoList, demoItem,
dyScroll: -48.0,
alignment: 0.5,
timeout: const Duration(seconds: 30),
);
for (int i = 0; i < 2; i += 1) {
@@ -217,6 +218,6 @@ void main([List<String> args = const <String>[]]) {
await runDemos(unprofiledDemos.toList(), driver);
}
});
}, timeout: const Timeout(Duration(minutes: 5)));
});
}

View File

@@ -18,6 +18,6 @@ void main() {
test('check that we are in normal mode', () async {
expect(await driver.requestData('status'), 'log: paint');
await driver.waitForAbsent(find.byType('PerformanceOverlay'));
await driver.waitForAbsent(find.byType('PerformanceOverlay'), timeout: Duration.zero);
});
}

View File

@@ -18,6 +18,6 @@ void main() {
test('check that we are showing the performance overlay', () async {
await driver.requestData('status'); // force a reassemble
await driver.waitFor(find.byType('PerformanceOverlay'));
await driver.waitFor(find.byType('PerformanceOverlay'), timeout: Duration.zero);
});
}

View File

@@ -18,6 +18,6 @@ void main() {
await driver.close();
});
test('empty', () async {});
test('empty', () async {}, timeout: const Timeout(Duration(minutes: 1)));
});
}

View File

@@ -48,6 +48,6 @@ void main() {
imageBefore = imageAfter;
}
});
}, timeout: const Timeout(Duration(minutes: 2)));
});
}