Add Android lifecycles test (#99319)

This commit is contained in:
Emmanuel Garcia
2022-03-01 15:26:21 -08:00
committed by GitHub
parent 64d9ea60b1
commit 6c818d772a
6 changed files with 287 additions and 55 deletions

View File

@@ -545,7 +545,7 @@ class AndroidDevice extends Device {
}
}
/// Executes [command] on `adb shell` and returns its exit code.
/// Executes [command] on `adb shell`.
Future<void> shellExec(String command, List<String> arguments, { Map<String, String>? environment, bool silent = false }) async {
await adb(<String>['shell', command, ...arguments], environment: environment, silent: silent);
}
@@ -637,7 +637,7 @@ class AndroidDevice extends Device {
late final StreamController<String> stream;
stream = StreamController<String>(
onListen: () async {
await adb(<String>['logcat', '--clear']);
await adb(<String>['logcat', '-c']);
final Process process = await startProcess(
adbPath,
// Make logcat less chatty by filtering down to just ActivityManager