Sometimes we have to use a custom mock to avoid retain cycles in OCMock. Used for testing low memory notification.
Definition at line 218 of file FlutterViewControllerTest.mm.
| - (BOOL) runWithEntrypoint: |
|
(nullable NSString *) |
NS_SWIFT_UI_ACTOR |
|
Runs a Dart program on an Isolate from the main Dart library (i.e. the library that contains main()), using "/" (the default route) as the initial route.
The first call to this method creates a new Isolate and returns YES. Subsequent calls return NO immediately and have no effect.
This method must be called on the main thread. See the FlutterEngine class documentation.
- Parameters
-
| entrypoint | The name of a top-level function from the same Dart library that contains the app's main() function. If this is FlutterDefaultDartEntrypoint (or nil) it will default to main(). If it is not the app's main() function, that function must be decorated with @pragma(vm:entry-point) to ensure the method is not tree-shaken by the Dart compiler. |
- Returns
- YES if this call started the engine; NO if it was already invoked, has been destroyed, or could not be started.
Reimplemented from FlutterEngine.
Definition at line 225 of file FlutterViewControllerTest.mm.
263 :(nullable NSString*)entrypoint {