Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
++
  • Loading branch information
matanlurey committed Feb 26, 2024
commit c799edb84a764fb532f96d3976cbe624fbc012da
55 changes: 36 additions & 19 deletions testing/scenario_app/bin/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,23 +24,40 @@ dart bin/android_integration_tests.dart --smoke-test dev.flutter.scenarios.Engin

## Additional arguments

- `--verbose`: Print additional information about the test run.

- `--adb`: The path to the `adb` tool. Defaults to
`third_party/android_tools/sdk/platform-tools/adb`.

- `--out-dir`: The directory containing the build artifacts. Defaults to the
last updated build directory in `out/` that starts with `android_`.

- `--logs-dir`: The directory to store logs and screenshots. Defaults to
`FLUTTER_LOGS_DIR` if set, or `out/.../scenario_app/logs` otherwise.

- `--use-skia-gold`: Use Skia Gold to compare screenshots. Defaults to true
when running on CI, and false otherwise (i.e. when running locally). If
set to true, `isSkiaGoldClientAvailable` must be true.

- `--enable-impeller`: Enable Impeller for the Android app. Defaults to
false, which means that the app will use Skia as the graphics backend.
```txt
-v, --verbose Enable verbose logging
-h, --help Print usage information
--[no-]enable-impeller Whether to enable Impeller as the graphics backend. If true, the
test runner will use --impeller-backend if set, otherwise the
default backend will be used. To explicitly run with the Skia
backend, set this to false (--no-enable-impeller).
--impeller-backend The graphics backend to use when --enable-impeller is true. Unlike
the similar option when launching an app, there is no fallback;
that is, either Vulkan or OpenGLES must be specified.
[vulkan (default), opengles]
--logs-dir Path to a directory where logs and screenshots are stored.
--out-dir=<path/to/out/android_variant> Path to a out/{variant} directory where the APKs are built.
Defaults to the latest updated out/ directory that starts with
"android_" if the current working directory is within the engine
repository.
--smoke-test=<package.ClassName> Fully qualified class name of a single test to run. For example try
"dev.flutter.scenarios.EngineLaunchE2ETest" or
"dev.flutter.scenariosui.ExternalTextureTests".
--output-contents-golden=<path/to/golden.txt> Path to a file that contains the expected filenames of golden
files. If the current working directory is within the engine
repository, defaults to
./testing/scenario_app/android/expected_golden_output.txt.
```

- `--impeller-backend`: The Impeller backend to use for the Android app.
Defaults to 'vulkan'. Only used when `--enable-impeller` is set to true.
## Advanced usage

```txt
--[no-]use-skia-gold Whether to use Skia Gold to compare screenshots. Defaults to true
on CI and false otherwise.
--adb=<path/to/adb> Path to the Android Debug Bridge (adb) executable. If the current
working directory is within the engine repository, defaults to
./third_party/android_tools/sdk/platform-tools/adb.
--ndk-stack=<path/to/ndk-stack> Path to the NDK stack tool. Defaults to the checked-in version in
third_party/android_tools if the current working directory is
within the engine repository on a supported platform.
```
4 changes: 3 additions & 1 deletion testing/scenario_app/bin/utils/options.dart
Original file line number Diff line number Diff line change
Expand Up @@ -105,16 +105,18 @@ extension type const Options._(ArgResults _args) {
/// Unlike [_miniParser], this parser includes all options.
static ArgParser _parser(Environment environment, Engine? localEngine) {
final bool hideUnusualOptions = !environment.showVerbose;
return ArgParser()
return ArgParser(usageLineLength: 120)
..addFlag(
'verbose',
abbr: 'v',
help: 'Enable verbose logging',
negatable: false,
)
..addFlag(
'help',
abbr: 'h',
help: 'Print usage information',
negatable: false,
)
..addFlag(
'use-skia-gold',
Expand Down