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

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

Issue 13956028: Remove dartdoc specific methods from dart2js_mirror. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove stale comment. 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
« no previous file with comments | « sdk/lib/_internal/dartdoc/lib/src/dart2js_mirrors.dart ('k') | tools/dom/docs/lib/docs.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/mirrors_test.dart
diff --git a/tests/compiler/dart2js/mirrors_test.dart b/tests/compiler/dart2js/mirrors_test.dart
index 6726116581f961c8675dd7b2b04873cf4f4e1283..317b12cc2d6b669cd73e48c031419203955c5f7a 100644
--- a/tests/compiler/dart2js/mirrors_test.dart
+++ b/tests/compiler/dart2js/mirrors_test.dart
@@ -6,6 +6,9 @@ import "package:expect/expect.dart";
import '../../../sdk/lib/_internal/compiler/implementation/mirrors/mirrors.dart';
import '../../../sdk/lib/_internal/compiler/implementation/mirrors/mirrors_util.dart';
import '../../../sdk/lib/_internal/compiler/implementation/mirrors/dart2js_mirror.dart';
+import '../../../sdk/lib/_internal/compiler/implementation/filenames.dart'
+ show currentDirectory, nativeToUriPath;
+import '../../../sdk/lib/_internal/compiler/implementation/source_file_provider.dart';
import 'dart:io';
import 'dart:uri';
@@ -40,12 +43,16 @@ DeclarationMirror findMirror(Iterable<DeclarationMirror> list, String name) {
}
main() {
- var scriptPath = new Path(new Options().script);
- var dirPath = scriptPath.directoryPath;
- var libPath = dirPath.join(new Path('../../../sdk/'));
- var inputPath = dirPath.join(new Path('mirrors_helper.dart'));
- var result = analyze([inputPath], libPath,
- options: <String>['--preserve-comments']);
+ Uri scriptUri =
+ currentDirectory.resolve(nativeToUriPath(new Options().script));
+ Uri libUri = scriptUri.resolve('../../../sdk/');
+ Uri inputUri = scriptUri.resolve('mirrors_helper.dart');
+ var provider = new SourceFileProvider();
+ var diagnosticHandler =
+ new FormattingDiagnosticHandler(provider).diagnosticHandler;
+ var result = analyze([inputUri], libUri, null,
+ provider.readStringFromUri, diagnosticHandler,
+ <String>['--preserve-comments']);
result.then((MirrorSystem mirrors) {
test(mirrors);
});
« no previous file with comments | « sdk/lib/_internal/dartdoc/lib/src/dart2js_mirrors.dart ('k') | tools/dom/docs/lib/docs.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698