Skip to content
pubscout

patrol_cli

4.9.0, released 3 weeks ago by leancode.co

Command-line tool to run and debug Patrol UI tests on multiple platforms

Rock solid
$ flutter pub add patrol_cli
Source repository

What it does

Patrol CLI activates globally and provides commands such as `patrol test` and `patrol coverage pull` to execute end‑to‑end UI tests and collect coverage. It supports native interactions, shell completion, and analytics control.

AI-written summary of version 4.9.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to run Patrol tests from CI or locally via terminal
  • You want to generate coverage reports for Android and Dart code
  • You need shell completion for bash/zsh/fish

Skip it when

  • You only run tests inside IDE or via Flutter's integration_test
  • You need a GUI test runner
  • You are on a platform not supported by Patrol

Strengths

  • Cross‑platform support (Android, iOS, web, desktop)
  • Handles native interactions beyond integration_test
  • CLI offers shell completion and analytics opt‑out
  • Coverage extraction for JaCoCo and Dart

Weaknesses

  • Requires Dart >=2.18
  • Relies on external tools like adb, idevicesyslog
  • Not a library, only a CLI tool
  • Limited to Patrol framework

Setup

Kind
Pure Dart
Effort
Medium
Code generation
No
Direct dependencies
24

Activate globally with `dart pub global activate patrol_cli`; add `$HOME/.pub-cache/bin` to PATH; ensure Dart >=2.18 and platform tools (adb, Xcode) are installed.

```bash
$ dart pub global activate patrol_cli
$ patrol test
```

Alternatives

Packages that do the same job and could replace patrol_cli.

  • fluttersdk_dusk

    Flutter E2E test driver for LLM agents and CLI via VM Service extensions without a test harness.

  • test_rocket

    A command-line tool to execute Dart and Flutter tests at high speed.

  • flame_test

    Classes and helpers for testing applications built with the Flame Engine.

  • test

    A full featured library for writing and running Dart tests across platforms.

Works with

Packages commonly used together with patrol_cli: ones it builds on, ones built on it, and its own family.