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

Unified Diff: tests/compiler/dart2js/dart_backend_test.dart

Issue 14070010: Refactor Future constructors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Added co19 issue number. Created 7 years, 8 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: tests/compiler/dart2js/dart_backend_test.dart
diff --git a/tests/compiler/dart2js/dart_backend_test.dart b/tests/compiler/dart2js/dart_backend_test.dart
index 3a4c2fca887d5c07aa8111cb37a4f80f485ab035..9e21cba6a39da6055a1f058d8a7517b9b201650e 100644
--- a/tests/compiler/dart2js/dart_backend_test.dart
+++ b/tests/compiler/dart2js/dart_backend_test.dart
@@ -92,25 +92,25 @@ testDart2DartWithLibrary(
final libUri = fileUri('mylib.dart');
provider(uri) {
- if (uri == scriptUri) return new Future.immediate(srcMain);
+ if (uri == scriptUri) return new Future.value(srcMain);
if (uri.toString() == libUri.toString()) {
- return new Future.immediate(srcLibrary);
+ return new Future.value(srcLibrary);
}
if (uri.path.endsWith('/core.dart')) {
- return new Future.immediate(coreLib);
+ return new Future.value(coreLib);
} else if (uri.path.endsWith('/io.dart')) {
- return new Future.immediate(ioLib);
+ return new Future.value(ioLib);
} else if (uri.path.endsWith('/js_helper.dart')) {
- return new Future.immediate(helperLib);
+ return new Future.value(helperLib);
} else if (uri.path.endsWith('/html_dart2js.dart')) {
// TODO(smok): The file should change to html_dartium at some point.
- return new Future.immediate(htmlLib);
+ return new Future.value(htmlLib);
} else if (uri.path.endsWith('/foreign_helper.dart')) {
- return new Future.immediate(foreignLib);
+ return new Future.value(foreignLib);
} else if (uri.path.endsWith('/isolate_helper.dart')) {
- return new Future.immediate(isolateHelperLib);
+ return new Future.value(isolateHelperLib);
}
- return new Future.immediate('');
+ return new Future.value('');
}
handler(uri, begin, end, message, kind) {
« no previous file with comments | « tests/compiler/dart2js/analyze_only_test.dart ('k') | tests/compiler/dart2js/memory_source_file_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698