-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Call tests via flutter test
instead of flutter drive
possible?
#275
Comments
Also calling this with
results in:
Note the "All tests passed!", which sould not occur. |
The problem seems to be that the generated executeTestSuite method is synchronous, but the run method is asynchronous:
Also the main method is done before the test setup is complete:
But Flutter assumes that with the end of the main method the test declaration is finished and does not allow any more calls on the test api (group, test, testWidgets, ...) You could probably make the executeTestSuite method asynchronous and await it.
What do you think @jonsamwell ? |
@luvetter I edited you comment to translate the german sentence 😉 |
Can you use integration_test package instead of driver package to test the app?
Use:
Instead of:
But I get the error with
flutter test
:I used the example in integration_test__package_support: https://github.com/jonsamwell/flutter_gherkin/tree/integration_test__package_support/example_with_integration_test
I also tested
flutter run
with tagExpression@failure-expected
, but then the result doesn't match the failure:The text was updated successfully, but these errors were encountered: