throwsFlutterError top-level property
A matcher for functions that throw FlutterError.
This is equivalent to throwsA(isA<FlutterError>())
.
If you are trying to test whether a call to WidgetTester.pumpWidget results in a FlutterError, see TestWidgetsFlutterBinding.takeException.
See also:
- throwsAssertionError, to test if a function throws any AssertionError.
- throwsArgumentError, to test if a functions throws an ArgumentError.
- isFlutterError, to test if any object is a FlutterError.
Implementation
final Matcher throwsFlutterError = throwsA(isFlutterError);