-
Notifications
You must be signed in to change notification settings - Fork 4k
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
🐛 [firebase_core] Is not compatible with headless integration testing. #11302
Comments
Thanks for the report @polina-c |
Thank you for checking. The same issue applies to unit testing.
|
Is there workaround? I really want to test cover user flows, so that GitHub bots could verify them on presubmit. What is recommended device for testing features, that use firestore, on GitHub bots? |
Tagging @Lyokone @russellwheatley for their input on this. |
Hi @polina-c, just to clarify, presumably you still mean running integration tests on an emulator, simulator or Chrome driver without the GUI also running? |
I am interested to run tests by github bots on presubmit. But I am open in terms of what test engine and what device to use. I created some implementation (see PR), but it is just one option. Does it answer the question? |
Ok, I think I understand what you mean. We don't have any integration tests that currently handle UI input/feedback, etc. Having said that, we are interested in this draft PR submitted by a member of the Patrol team: #11378 It uses Patrol to handle API that requires UI input/feedback. Read more about Patrol here: https://pub.dev/packages/patrol Hope that helps! |
Let me make sure there is no misunderstanding. However, calls to firebase backend fail, because platform is detected as android, while it is not android. It would be very beneficial to enable Flutter integration tests to to verify user flows that work with authentication and database. Does it change something? |
If it is running headless, it won't run on a GUI (i.e. emulator/simulator). FlutterFire is ultimately a wrapper around the native SDKs which require a non-headless environment to communicate with the native platforms. |
thank you! |
I don't know enough about GitHub bot capabilities to give you an answer on that I'm afraid. I can point you in the direction of where our e2e tests are ran via GitHub actions, this is android & this is iOS a summary of what is happening in each action:
|
Thanks. |
Hello @polina-c, after discussing it internally, we will not add instructions on how to integrate CI/CD with FlutterFire because we feel it would duplicate informations that can be found elsewhere and that are highly dependent on other CI platforms like GitHub Actions, Codemagic or else ... Please found the current official instructions here: https://firebase.google.com/docs/test-lab/flutter/integration-testing-with-flutter |
Firebase fails to setup connection for integration test for headless device (It succeeds for
-d macos
though).Steps to repro:
cd pkgs/date_game
flutter test integration_test/app_test.dart -d flutter-tester
Output for
print('!!!! defaultTargetPlatform: $defaultTargetPlatform')
is!!!! defaultTargetPlatform: TargetPlatform.android
.Error:
The text was updated successfully, but these errors were encountered: