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

Unified Diff: test/runner/browser/runner_test.dart

Issue 1667663005: Fix a few more timeout tests. (Closed) Base URL: git@github.com:dart-lang/test@master
Patch Set: Created 4 years, 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/runner/browser/runner_test.dart
diff --git a/test/runner/browser/runner_test.dart b/test/runner/browser/runner_test.dart
index dcd18c694b6fca0d1981c0a28517c88a3b9b7b60..07af765a414cd323db2482a5f6cfd999a6e76912 100644
--- a/test/runner/browser/runner_test.dart
+++ b/test/runner/browser/runner_test.dart
@@ -459,7 +459,7 @@ import 'dart:async';
import 'package:test/test.dart';
void main() {
- test("timeout", () {});
+ test("timeout", () => new Future.delayed(Duration.ZERO));
}
''').create();
@@ -511,8 +511,11 @@ import 'dart:async';
import 'package:test/test.dart';
void main() {
- test("fail", () => throw 'oh no', onPlatform: {
- "browser": new Timeout(new Duration(seconds: 0))
+ test("fail", () async {
+ await new Future.delayed(Duration.ZERO);
+ throw 'oh no';
+ }, onPlatform: {
+ "browser": new Timeout(Duration.ZERO)
});
}
''').create();
@@ -618,7 +621,10 @@ import 'dart:async';
import 'package:test/test.dart';
void main() {
- test("fail", () => throw 'oh no');
+ test("fail", () async {
+ await new Future.delayed(Duration.ZERO);
+ throw 'oh no';
+ });
}
''').create();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698