Set a longer default timeout for dartdev.dart tests so flakiness is removed from the bots. Reason in utils.dart:

/// A long [Timeout] is provided for tests that start a process on
/// `bin/dartdev.dart` as the command is not compiled ahead of time, and each
/// invocation requires the VM to compile the entire dependency graph.

Change-Id: Ieec2238b5fb7358af5e9924912eaf2580d5dbfb1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143181
Commit-Queue: Siva Annamalai <asiva@google.com>
Auto-Submit: Jaime Wren <jwren@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
This commit is contained in:
Jaime Wren 2020-04-14 04:19:29 +00:00 committed by commit-bot@chromium.org
parent 4aa896464a
commit 5bf1223ea9
10 changed files with 14 additions and 11 deletions

View file

@ -7,7 +7,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('analyze', defineAnalyze, timeout: defaultTimeout);
group('analyze', defineAnalyze, timeout: longTimeout);
}
const String _analyzeDescriptionText = "Analyze the project's Dart code.";

View file

@ -12,7 +12,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('create', defineCreateTests);
group('create', defineCreateTests, timeout: longTimeout);
}
void defineCreateTests() {

View file

@ -9,8 +9,8 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('command', command);
group('flag', help);
group('command', command, timeout: longTimeout);
group('flag', help, timeout: longTimeout);
}
void command() {

View file

@ -9,7 +9,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('format', format);
group('format', format, timeout: longTimeout);
}
void format() {

View file

@ -9,7 +9,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('help', help);
group('help', help, timeout: longTimeout);
}
void help() {

View file

@ -8,7 +8,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('migrate', defineMigrateTests);
group('migrate', defineMigrateTests, timeout: longTimeout);
}
// TODO(jcollins-g): Set to true and/or remove when when NNBD is enabled in the

View file

@ -7,7 +7,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('pub', pub);
group('pub', pub, timeout: longTimeout);
}
void pub() {

View file

@ -9,7 +9,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('run', run);
group('run', run, timeout: longTimeout);
}
void run() {

View file

@ -7,7 +7,7 @@ import 'package:test/test.dart';
import '../utils.dart';
void main() {
group('test', defineTest);
group('test', defineTest, timeout: longTimeout);
}
void defineTest() {

View file

@ -7,7 +7,10 @@ import 'dart:io';
import 'package:path/path.dart' as path;
import 'package:test/test.dart';
Timeout defaultTimeout = Timeout(Duration(seconds: 15));
/// A long [Timeout] is provided for tests that start a process on
/// `bin/dartdev.dart` as the command is not compiled ahead of time, and each
/// invocation requires the VM to compile the entire dependency graph.
const Timeout longTimeout = Timeout(Duration(minutes: 5));
TestProject project({String mainSrc, String analysisOptions}) {
return TestProject(mainSrc: mainSrc, analysisOptions: analysisOptions);