pumpAndTrySettle method
Future<void>
pumpAndTrySettle({
- Duration duration = const Duration(milliseconds: 100),
- Duration? timeout = const Duration(seconds: 2),
- EnginePhase? phase = EnginePhase.sendSemanticsUpdate,
override
Implementation
@override
Future<void> pumpAndTrySettle({
Duration duration = const Duration(milliseconds: 100),
Duration? timeout = const Duration(seconds: 2),
EnginePhase? phase = EnginePhase.sendSemanticsUpdate,
}) async {
try {
await _tester.pumpAndSettle(
duration,
phase ?? EnginePhase.sendSemanticsUpdate,
timeout ?? config.settleTimeout,
);
} on FlutterError catch (err) {
if (err.message == 'pumpAndSettle timed out') {
// This is fine. This method ignores pumpAndSettle timeouts on purpose
} else {
rethrow;
}
}
}