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

Side by Side Diff: tests/compiler/dart2js/missing_file_test.dart

Issue 23583041: Don't expect String on read-errors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // Test that the compiler can handle imports when package root has not been set. 5 // Test that the compiler can handle imports when package root has not been set.
6 6
7 library dart2js.test.missing_file; 7 library dart2js.test.missing_file;
8 8
9 import 'package:expect/expect.dart'; 9 import 'package:expect/expect.dart';
10 import "package:async_helper/async_helper.dart"; 10 import "package:async_helper/async_helper.dart";
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 asyncTest(() => compiler.run(main).then((_) { 62 asyncTest(() => compiler.run(main).then((_) {
63 Expect.equals(1, errors.length); 63 Expect.equals(1, errors.length);
64 Expect.equals(expectedMessage, 64 Expect.equals(expectedMessage,
65 errors[0]); 65 errors[0]);
66 })); 66 }));
67 } 67 }
68 68
69 void main() { 69 void main() {
70 runCompiler(Uri.parse('memory:main.dart'), 70 runCompiler(Uri.parse('memory:main.dart'),
71 "Error: Can't read 'memory:foo.dart' " 71 "Error: Can't read 'memory:foo.dart' "
72 "(No such file memory:foo.dart)."); 72 "(Exception: No such file memory:foo.dart).");
73 runCompiler(Uri.parse('memory:foo.dart'), 73 runCompiler(Uri.parse('memory:foo.dart'),
74 "Error: Can't read 'memory:foo.dart' " 74 "Error: Can't read 'memory:foo.dart' "
75 "(No such file memory:foo.dart)."); 75 "(Exception: No such file memory:foo.dart).");
76 runCompiler(Uri.parse('dart:foo'), 76 runCompiler(Uri.parse('dart:foo'),
77 'Error: Library not found "dart:foo".'); 77 'Error: Library not found "dart:foo".');
78 } 78 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698