Тёмный

Flutter Integration Test Tutorial + Firebase Test Lab & Codemagic 

Reso Coder
Подписаться 112 тыс.
Просмотров 34 тыс.
50% 1

📗 Learn from the written tutorial 👇👇
resocoder.com/flutter-integra...
✨ Codemagic CI/CD built with Flutter in mind:
codemagic.io
📧 Get Flutter news 📰 and resources:
👉 flutter.education
👨‍💻 Do you write good code? Find out now!
resocoder.com/good-code-quiz
Unit tests, widget tests, integration tests - that's the testing pyramid you're probably familiar with. The first two have always been quite easy to write and quick to execute. However, integration tests, which are the focus of this tutorial, have had a fair share of their problems - they used to be unnecessarily hard to write and impossible to run on device farms such as Firebase Test Lab. That is, until we had the integration_test package!
Go to my website for more information, code examples, and articles:
● resocoder.com
Follow me on social media:
● / resocoder
● / resocoder
● / resocoder

Опубликовано:

 

1 янв 2021

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 55   
@georgevincent4447
@georgevincent4447 3 года назад
What I have been waiting for!
@rebarius
@rebarius 3 года назад
Brilliant! I love your videos Reso ❤️❤️
@StefanoSaitta
@StefanoSaitta 3 года назад
This is totally what we needed right now, great timing! Thank you so much
@ResoCoder
@ResoCoder 3 года назад
I'm glad this tutorial helped you, Stefano!
@Mark-og2cu
@Mark-og2cu 3 года назад
Thank you for the very detailed explanation of every step!
@h3w45
@h3w45 3 года назад
Thanks for covering flutter.
@muhammedmsr1224
@muhammedmsr1224 3 года назад
How can I tap on native location permission popup during integration test ?
@jalvessimoes
@jalvessimoes 3 года назад
Very cool video. thanks!
@tanoth1pl
@tanoth1pl 3 года назад
Hey Resco, thank you for your video. I have a question about implementing a Page object to integration tests. Could you make a short and simple video about it? I have done that for flutter driver but now I'm not sure how to refactor my framework to use page object in this new package. I will appreciate that a lot. Best regards :)
@adamkonecnycz
@adamkonecnycz 3 года назад
Yeah, finally!!! You are simply the best :-D Please can you make end-to-end testing tutorial ?
@ResoCoder
@ResoCoder 3 года назад
Thank you! The integration_test package was previously called "e2e" and as I've mentioned in the video, integration tests in Flutter are basically UI tests (which is a synonym for e2e tests in my opinion). Mimochodom, ahoj Adam! 😅
@adamkonecnycz
@adamkonecnycz 3 года назад
@@ResoCoderAhoooj :-D. Pár měsíců zpátky jsem psal něco v češtině :D
@supersciencounet
@supersciencounet 3 года назад
Why not using the codemagic tool "Encrypt environment variable" to encrypt the json file? But still a great tutorial again Matt, thank you so much for your work!
@moseskarunia
@moseskarunia 3 года назад
Thanks!
@Usakyi
@Usakyi 3 года назад
Oh my Lord Amazing
@Usakyi
@Usakyi 3 года назад
Thank you for your work!!
@sandormartin4549
@sandormartin4549 2 года назад
Thanks for the video, I'm developing integration tests in my app, but I ran into a problem with the permissions. You know that if we try to use the camera, geolocation or any other service of the phone the operating system requires allow its use. So when an integration test is being developed this modal appears and I'm not able to find a solution to allow it. Any idea?
@mmazurovsky_r
@mmazurovsky_r 2 года назад
Thanks for a great tutorial. Unfortunately, I can't make run integration tests that use files from assets in Firebase Test Lab. The Test Lab does not provide proper logs so it took me 3 days to figure out the problem is connected with reading files. I have not found a work around yet for the issue
@hinnarutaba1815
@hinnarutaba1815 2 года назад
Hey, great video! but it would be nice if you can make a tutorial on iOS as well using Codemagic and Firebase Test Lab. I've been trying to do it for flutter iOS but dead end.
@pfote65
@pfote65 3 года назад
looks pretty complicated. very helpful video though, thanks. liked and subscribed
@tanmaykumar6426
@tanmaykumar6426 3 года назад
Sir could you pls make some videos on rxdart and streams
@brenoaugustodasilvamoreno6044
@brenoaugustodasilvamoreno6044 3 года назад
How about the web part? It would be a good video as well!
@parthsuthar6393
@parthsuthar6393 3 года назад
Any example while testing with calling APIs and handling its response.?
@UnsentPH
@UnsentPH 3 года назад
hi, can you make a full tutorial to set up flutter with emulator android for windows, thank you
@TalkToMeMax
@TalkToMeMax 2 года назад
any idea how to tap on location permission native popup?
@juanignacioagu960
@juanignacioagu960 3 года назад
Is possible run integration_test for iOS on Firebase Test Lab?
@van_tigranyan
@van_tigranyan 2 года назад
Which VSCode theme is this?
@ductrandinhvti.d2692
@ductrandinhvti.d2692 3 года назад
Hello, I have an unrelated question, I want to use flutter driver to implement automated test. And I want to run multiple test cases of Flutter integration tests in single command or from single file. Do you know anyway to do this?
@user-lw3rm3sc4f
@user-lw3rm3sc4f 7 месяцев назад
You can make a main file to tests and call all of your tests in this file and run this file
@devanshshukla4076
@devanshshukla4076 2 года назад
How to enter text to a custom text field like OTPTextField?
@dpirs
@dpirs 3 года назад
One more question if anyone can help or explain - when I run my test usign 'flutter drive ...' command , I can see fine how tests are executing on my mobile device (or simulator). But when I run the tests from VSCode in debug mode (so that I'm able to debug them), they are executed, but I cannot see any updates on my mobile device. It is like they are running in background or something.
@ivanhorchakov2411
@ivanhorchakov2411 3 года назад
They are executing in Dart VM (virtual machine).
@klausgreinerfiorini
@klausgreinerfiorini 3 года назад
Ios version as well?
@huxhtipo
@huxhtipo 2 года назад
Hey Reso, Are you going to update the video?
@syumak635
@syumak635 2 года назад
how do you incorporate Appium in the integration test for Flutter test?
@Rithless
@Rithless 2 года назад
yeah, im in a spot where we are deciding do we go for flutter solution or java + selenium + appium ( which i prefer in long run i think ), but im not sure, flutter is not providing selectors for selenium, just xpaths and ocassionaly accesibleId :/
@mars3142
@mars3142 3 года назад
Haha. In 54:19 you will see the index 2 (2nd run) of the build. And 2 secs later (54:21) the index has magically increased to index 4. So there are two more build failures, but the commit hash is the same, so it seems to be a configuration failure in codemagic. Am I right?
@ResoCoder
@ResoCoder 3 года назад
I messed up with a configuration step which I then outlined in the video as if nothing happened through the power of video editing 😄
@josephbhanini553
@josephbhanini553 3 года назад
Well perfect as usual , i have a question : Im developping an app which have a KYC part which consist of 4 chapters and each chapter have 10 pages and each page have 4 to 5 textformfield also gender , date and select options .. etc Should i do integeration test and waste that much time on it ? Im using my actual device and also testing each page and each textfield once i finish coding this page .
@dpirs
@dpirs 3 года назад
There is no general answer to this question. It is up to you to decide how many tests on each test level you need and can affort (writing tests is time consuming). See martinfowler.com/articles/practical-test-pyramid.html for more details
@josephbhanini553
@josephbhanini553 3 года назад
@@dpirs thankss i will check it out
@MoAdel92
@MoAdel92 2 года назад
The library 'package:integration_test/integration_test.dart' is legacy, and should not be imported into a null safe library. Try migrating the imported library.dart(import_of_leg
@Vycgaudas
@Vycgaudas 3 года назад
What is the benefit of using integration_test vs the flutter_driver?
@ResoCoder
@ResoCoder 3 года назад
As I've mentioned, integration_test uses the much easier to write widget testing API and also, you can run these tests on Firebase Test Lab.
@NaraAIApp
@NaraAIApp 3 года назад
Hi thank you so much for your video, but I have question, why when i try to use Firebase Test Lab, it says "Test failed to run". But actually it works perfectly in my local machine when I try to use flutter drive. Is there any way to reproduce this issue in my local machine? Or do you know how to solve this. Btw, when i try to run your project on my firebase test lab, it also works perfectly. Thankss!
@ivanhorchakov2411
@ivanhorchakov2411 3 года назад
Probably something wrong with your CLI commands to FTL. Also, you can run them locally (but firstly build apk) not via "flutter drive ..." (with a host) but via "./gradlew app:connectedAndroidTest -Ptarget=`pwd`/../integration_test/app_test.dart -Pandroid.debug.obsoleteApi=true" from "android" folder (without a host - directly on an emulator or real device).
@gabrielfontanari4488
@gabrielfontanari4488 2 года назад
​@@ivanhorchakov2411 Is there a way to pass --dart-define when using gradle to build the app?
@ivanhorchakov2411
@ivanhorchakov2411 2 года назад
@@gabrielfontanari4488 you'll not believe me, but I was wondering how to pass "--dart-define" in Firebase TL run too :). Actually, your idea can help - please tell me if you've already tried it or I'll try it by myself.
@shivz732
@shivz732 3 года назад
How is this info free, amazing video. Thank you
@sachinsoma5757
@sachinsoma5757 Год назад
Great tutorial ! . Can we also execute this script using codemagic.yaml file right?
@archielyndizon2869
@archielyndizon2869 2 года назад
🤔
Далее
Flutter Bloc & Cubit Tutorial
47:58
Просмотров 120 тыс.
Flutter Testing For Beginners - The Ultimate Guide
13:05
Rethinking Dart interoperability with Android
16:02
Просмотров 15 тыс.
Snackbar, Toast & Dialog in Flutter (Flash Package)
32:13
TypeScript Origins: The Documentary
1:21:36
Просмотров 280 тыс.
Freezed ❄ - Data Class & Union in One Dart Package
36:28