Sync test code with Cocoon (#6129)
* fix flutter watch benchmark Syncsd2d7950ecd* Split Android/iOS impl behind a unified interface Syncsdb87e10fa5* Switch from pub get to flutter packages get Syncsb378005cbb* "silent" option in test runner; fix analysis errors;
This commit is contained in:
@@ -51,9 +51,11 @@ Future<Null> main(List<String> rawArgs) async {
|
||||
return null;
|
||||
}
|
||||
|
||||
bool silent = args['silent'];
|
||||
|
||||
for (String taskName in taskNames) {
|
||||
section('Running task "$taskName"');
|
||||
Map<String, dynamic> result = await runTask(taskName);
|
||||
Map<String, dynamic> result = await runTask(taskName, silent: silent);
|
||||
|
||||
if (!result['success'])
|
||||
exitCode = 1;
|
||||
@@ -98,4 +100,9 @@ final ArgParser _argParser = new ArgParser()
|
||||
);
|
||||
}
|
||||
},
|
||||
)
|
||||
..addFlag(
|
||||
'silent',
|
||||
negatable: true,
|
||||
defaultsTo: false,
|
||||
);
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createComplexLayoutStartupTest(ios: false));
|
||||
await task(createComplexLayoutStartupTest(os: DeviceOperatingSystem.android));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createComplexLayoutStartupTest(ios: true));
|
||||
await task(createComplexLayoutStartupTest(os: DeviceOperatingSystem.ios));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createComplexLayoutScrollPerfTest(ios: false));
|
||||
await task(createComplexLayoutScrollPerfTest(os: DeviceOperatingSystem.android));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createComplexLayoutScrollPerfTest(ios: true));
|
||||
await task(createComplexLayoutScrollPerfTest(os: DeviceOperatingSystem.ios));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createFlutterGalleryStartupTest(ios: false));
|
||||
await task(createFlutterGalleryStartupTest(os: DeviceOperatingSystem.android));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createGalleryTransitionTest(ios: false));
|
||||
await task(createGalleryTransitionTest(os: DeviceOperatingSystem.android));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createFlutterGalleryStartupTest(ios: true));
|
||||
await task(createFlutterGalleryStartupTest(os: DeviceOperatingSystem.ios));
|
||||
}
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<Null> main() async {
|
||||
await task(createGalleryTransitionTest(ios: true));
|
||||
await task(createGalleryTransitionTest(os: DeviceOperatingSystem.ios));
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ import 'package:flutter_devicelab/framework/utils.dart';
|
||||
|
||||
void main() {
|
||||
task(() async {
|
||||
Adb device = await adb();
|
||||
Device device = await devices.workingDevice;
|
||||
await device.unlock();
|
||||
Directory appDir =
|
||||
dir(path.join(flutterDirectory.path, 'examples/flutter_gallery'));
|
||||
|
||||
Reference in New Issue
Block a user