Questions tagged [flutter-patrol]

Use this tag for questions about Patrol - a testing framework for Flutter apps. If your question is platform-specific, tag the platform as well (e.g., [android], [ios], etc.). You may also wish to include the [dart] and [testing] tags.

Patrol is a testing framework for Flutter. It builds on top of Flutter's testing tools.

Patrol lets you access features of the platform that the Flutter app is running on. For example, you can go to the home screen, tap on notifications, change device settings, or toggle Wi-Fi – and you can code this very easily in Dart.

Patrol also provides a new custom finder system that extends Flutter's default finders. Patrol's custom finders make writing Flutter widget tests dramatically faster and easier.

Docs: https://patrol.leancode.co

18 questions
2
votes
0 answers

Flutter Patrol CLI - Xcode build error after Xcode update to version 14.3

After updating Xcode, the build for the integration tests fails. I get the following error: 2023-05-04 10:02:20.872 xcodebuild[42145:1120855] DVTCoreDeviceEnabledState: DVTCoreDeviceEnabledState_Disabled set via user default…
Florian
  • 21
  • 2
2
votes
1 answer

ASK Flutter Integration test with Patrol

I try to learn how to write full automation tests in Flutter. in my case, I have 3 flavor apps (Development, Staging, and Production), and some modules need some native integration with OS itself like opening a web browser, etc. I try some different…
2
votes
1 answer

Using patrol test package for google sign in during integration test error

I am unable to select the particular email for google sign-in for testing this is the error that im facing. _AssertionError ('package:patrol/src/custom_finders/patrol_tester.dart': Failed assertion: line 131 pos 7: 'nativeAutomator != null':…
1
vote
1 answer

Flutter> Patrol > Mobile automatization test: How to access to "Subscribe" button on system pop-up Google Play Store?

I'm trying to purchase a subscription in my tests. Everything goes well until the native Android purchase popup appears. I'm not able to tap on the green 'Subscribe' button. Is there a way to do it? The following code doesn't work: ** See…
1
vote
1 answer

Build error when I use patrol cli command to test native screen

Getting below build errors when i use below patrol cli command to run test patrol test --target integration_test/example_test.dart **Build error 1 - Execution failed for task ':video_player_android:compileDebugJavaWithJavac'. > Compilation…
1
vote
1 answer

Unable to run Patrol test properly

i'm able to run integration_test using this codes: ########## # integration_test/openapp_test.dart ########## import 'package:myapp/main.dart' as app; group('end-to-end test', () { testWidgets('tap on the floating action button, verify…
1
vote
1 answer

Error when running Integration test in Flutter using patrol

I'm trying to run an integration test in flutter using the patrol 1.0.8 package. Then I got an error when running the test with commanded patrol test integration_test/classic_process_test.dart --verbose on ios physical device. Error is Error: No…
1
vote
1 answer

Undefined name Patrol in Flutter

Even though I added dependency correctly, it is unable to find the Patrol class inside the dependencies. The correct implementation is shown in this link: https://pub.dev/packages/patrol
0
votes
0 answers

Flutter> Patrol >Allure: Command for retrieve the results from the device (Windows)

This commad doesn't work for me on Windows: adb exec-out sh -c 'cd /sdcard/googletest/test_outputfiles && tar cf - allure-results' | tar xvf - -C build/reports Issue: tar.exe: Damaged tar archive tar.exe: Retrying... ( Command comes from doc:…
0
votes
0 answers

(Flutter-Patrol) How can I run few patrol's tests in the directory to execute one file/test only once?

The following hierarchy of the integration_test directory: integration_test ├── patrol    ├── 1_test.dart    ├── 2_test.dart ├── 3_test.dart ├── 4_test.dart ├── 5_test.dart └── 6_test.dart Command to run tests (windows): patrol test -t…
0
votes
1 answer

I have setup the codemagic.yaml and Patrol package for testing the integration test cases but I am facing one issue

here is my .yaml file for CI/CD . I used the patrol package for write test cases. https://patrol.leancode.co/getting-started/getting-started workflows: android_dev_workflow: name: workflow for integration testing instance_type: mac_mini_m1 …
yash oza
  • 11
  • 3
0
votes
0 answers

I implemented patrol(https://patrol.leancode.co/) package for perform the integration testing in my current project.enterText() method is not working

I used patrol package here is my test cases for Pinput widget. final TextEditingController controller = TextEditingController(); const length = 4; final focusNode = FocusNode(); final ref = ProviderContainer(); await…
0
votes
1 answer

_debugInitializedType == null': is not true thrown and ios app stuck on splashscreen while running via Patrol

Running e2e test via patrol for a flutter written app. Exception has occurred. _AssertionError ('package:flutter/src/foundation/binding.dart': Failed assertion: line 149 pos 12: '_debugInitializedType == null': is not true.)
0
votes
1 answer

Looking for guidance on testing a complete food ordering and delivery process in Flutter

I am working on a project that involves three Flutter apps: a customer app, a driver app, and a pioneer app. We have already written integration tests for each app, but now we need to write a full end-to-end integration test that covers the entire…
0
votes
1 answer

Problem with Patrol while running integration test in Flutter

I have problem with Patrol while running integration test in Flutter. I need to accept some permissions and I want to use to this purpose Petrol package.But in terminal there is an error which seems like this: Patrol (native): configure()…
1
2