This reverts commit 0c9781e3dd.
This commit is contained in:
@@ -6,7 +6,7 @@ import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.android;
|
||||
await task(createGalleryTransitionTest(args));
|
||||
await task(createGalleryTransitionTest());
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.android;
|
||||
await task(createGalleryTransitionE2ETest(args));
|
||||
await task(createGalleryTransitionE2ETest());
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.ios;
|
||||
await task(createGalleryTransitionE2ETest(args));
|
||||
await task(createGalleryTransitionE2ETest());
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.ios;
|
||||
await task(createGalleryTransitionE2ETest(args));
|
||||
await task(createGalleryTransitionE2ETest());
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.android;
|
||||
await task(createGalleryTransitionHybridTest(args));
|
||||
await task(createGalleryTransitionHybridTest());
|
||||
}
|
||||
|
||||
@@ -7,11 +7,11 @@ import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
import 'package:flutter_devicelab/framework/task_result.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.android;
|
||||
await task(() async {
|
||||
final TaskResult withoutSemantics = await createGalleryTransitionTest(args)();
|
||||
final TaskResult withSemantics = await createGalleryTransitionTest(args, semanticsEnabled: true)();
|
||||
final TaskResult withoutSemantics = await createGalleryTransitionTest()();
|
||||
final TaskResult withSemantics = await createGalleryTransitionTest(semanticsEnabled: true)();
|
||||
if (withSemantics.benchmarkScoreKeys.isEmpty || withoutSemantics.benchmarkScoreKeys.isEmpty) {
|
||||
String message = 'Lack of data';
|
||||
if (withSemantics.benchmarkScoreKeys.isEmpty) {
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:flutter_devicelab/tasks/gallery.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main(List<String> args) async {
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.ios;
|
||||
await task(createGalleryTransitionTest(args));
|
||||
await task(createGalleryTransitionTest());
|
||||
}
|
||||
|
||||
@@ -14,23 +14,18 @@ Future<void> main(List<String> args) async {
|
||||
}
|
||||
|
||||
class FakeBuildTestTask extends BuildTestTask {
|
||||
FakeBuildTestTask(List<String> args) : super(args, runFlutterClean: false);
|
||||
FakeBuildTestTask(List<String> args) : super(args, runFlutterClean: false) {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.fake;
|
||||
}
|
||||
|
||||
@override
|
||||
// In prod, tasks always run some unit of work and the test framework assumes
|
||||
// there will be some work done when managing the isolate. To fake this, add a delay.
|
||||
Future<void> build() async {
|
||||
if (targetPlatform != DeviceOperatingSystem.fake) {
|
||||
throw Exception('Only DeviceOperatingSystem.fake is supported');
|
||||
}
|
||||
}
|
||||
Future<void> build() => Future<void>.delayed(const Duration(milliseconds: 500));
|
||||
|
||||
@override
|
||||
Future<TaskResult> test() async {
|
||||
if (targetPlatform != DeviceOperatingSystem.fake) {
|
||||
throw Exception('Only DeviceOperatingSystem.fake is supported');
|
||||
}
|
||||
|
||||
await Future<void>.delayed(const Duration(milliseconds: 500));
|
||||
return TaskResult.success(<String, String>{'benchmark': 'data'});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
// Copyright 2014 The Flutter Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
|
||||
import 'smoke_test_build_test.dart';
|
||||
|
||||
/// Smoke test of a build test task with [deviceOperatingSystem] set. This should
|
||||
/// only pass in tests run with target platform set to fake.
|
||||
Future<void> main(List<String> args) async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.ios;
|
||||
await task(FakeBuildTestTask(args));
|
||||
}
|
||||
Reference in New Issue
Block a user