FlutterWidgetTesterWorld class
The world object that can be used to store state during a single test.
It also allows interaction with the app under test through the appDriver
which exposes an instance of AppDriverAdapter
and an
instance of WidgetTester
via the property rawAppDriver
- Inheritance
-
- Object
- FlutterWorld
- FlutterTypedAdapterWorld<
WidgetTester, Finder, Widget> - FlutterWidgetTesterWorld
Constructors
Properties
-
appDriver
→ AppDriverAdapter<
WidgetTester, Finder, Widget> -
The adapter that is used to agnostically drive the app under test
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- rawAppDriver → WidgetTester
-
The underlying driver that is able to instrument the app under test
It is suggested you use
appDriver
for all interactions with the app under tests however if you need a specific api not available onappDriver
this property exposes the actual class that can interact with the app under testno setterinherited - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
attach(
String data, String mimeType, [String? context]) → void -
Attach data to the given
context
which can be a step name or if blank it will be attached to the scenariomimeType
one of 'text/plain', 'text/html', 'application/json', 'image/png'inherited -
dispose(
) → void -
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
restartApp(
{Duration? timeout = const Duration(seconds: 60)}) → Future< bool> -
Restart the app under test
inherited
-
setAppAdapter(
AppDriverAdapter appAdapter) → void -
Sets the app driver that is used to control the app under test
inherited
-
setAttachmentManager(
AttachmentManager attachmentManager) → void -
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited