Add first replay test (#8628)
diff --git a/dev/bots/test.dart b/dev/bots/test.dart index 5c2a505..71e4d58 100644 --- a/dev/bots/test.dart +++ b/dev/bots/test.dart
@@ -6,6 +6,7 @@ String flutterRoot = p.dirname(p.dirname(p.dirname(p.fromUri(Platform.script)))); String flutter = p.join(flutterRoot, 'bin', Platform.isWindows ? 'flutter.bat' : 'flutter'); String dart = p.join(flutterRoot, 'bin', 'cache', 'dart-sdk', 'bin', Platform.isWindows ? 'dart.exe' : 'dart'); +String pub = p.join(flutterRoot, 'bin', 'cache', 'dart-sdk', 'bin', Platform.isWindows ? 'pub.bat' : 'pub'); String flutterTestArgs = Platform.environment['FLUTTER_TEST_ARGS']; /// When you call this, you can set FLUTTER_TEST_ARGS to pass custom @@ -81,6 +82,9 @@ await _runAllDartTests(p.join(flutterRoot, 'packages', 'flutter_tools'), environment: <String, String>{ 'FLUTTER_ROOT': flutterRoot }, ); + await _pubRunTest(p.join(flutterRoot, 'packages', 'flutter_tools'), + testPath: 'test/replay', + ); await _runAllDartTests(p.join(flutterRoot, 'dev', 'devicelab')); await _runFlutterTest(p.join(flutterRoot, 'dev', 'manual_tests')); @@ -93,6 +97,16 @@ } } +Future<Null> _pubRunTest( + String workingDirectory, { + String testPath, +}) { + final List<String> args = <String>['run', 'test']; + if (testPath != null) + args.add(testPath); + return _runCmd(pub, args, workingDirectory: workingDirectory); +} + Future<Null> _runCmd(String executable, List<String> arguments, { String workingDirectory, Map<String, String> environment,