Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(282)

Unified Diff: pkg/scheduled_test/test/metatest.dart

Issue 13327009: Increase the default test timeout for scheduled tests on Windows. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/scheduled_test/test/metatest.dart
diff --git a/pkg/scheduled_test/test/metatest.dart b/pkg/scheduled_test/test/metatest.dart
index 0771ff41a42dee7e2fac9594c3129755760c77fd..71ad421fd9165c9adb29c5d598e2b37f84633103 100644
--- a/pkg/scheduled_test/test/metatest.dart
+++ b/pkg/scheduled_test/test/metatest.dart
@@ -15,6 +15,7 @@ import 'dart:isolate';
import 'package:pathos/path.dart' as path;
import 'package:unittest/unittest.dart';
+import 'package:scheduled_test/scheduled_test.dart' as scheduled_test;
import 'utils.dart';
@@ -71,6 +72,14 @@ void expectTestsFail(String description, void body()) {
});
}
+/// Runs [setUpFn] before every metatest. Note that [setUpFn] will be
+/// overwritten if the test itself calls [setUp].
+void metaSetUp(void setUpFn()) {
+ _inChildIsolate.then((inIsolate) {
+ if (inIsolate) scheduled_test.setUp(setUpFn);
+ });
+}
+
/// Sets up a test with the given [description] and [body]. After the test runs,
/// calls [validate] with the result map.
void _setUpTest(String description, void body(), void validate(Map)) {

Powered by Google App Engine
This is Rietveld 408576698