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

Unified Diff: tests/compiler/dart2js/mirrors/mirrors_test_helper.dart

Issue 150693005: Fix ParameterMirror.hasDefaultValue/defaultValue in source mirrors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix handling of external parameters Created 6 years, 10 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 | « tests/compiler/dart2js/mirrors/mirrors_reader_test.dart ('k') | tests/lib/lib.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/mirrors/mirrors_test_helper.dart
diff --git a/tests/compiler/dart2js/mirrors/mirrors_test_helper.dart b/tests/compiler/dart2js/mirrors/mirrors_test_helper.dart
index af4530526c4cf3b144548ea706babba80f294d70..e8f82fbdb32bc6cc95b935328527fa21b27d09fe 100644
--- a/tests/compiler/dart2js/mirrors/mirrors_test_helper.dart
+++ b/tests/compiler/dart2js/mirrors/mirrors_test_helper.dart
@@ -6,11 +6,11 @@ import 'dart:io';
import 'dart:async';
import 'dart:mirrors';
-import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/source_mirrors.dart' as source_mirrors;
+import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/source_mirrors.dart';
import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/analyze.dart' as source_mirrors;
import '../../../../sdk/lib/_internal/compiler/implementation/source_file_provider.dart';
-TypeMirror createInstantiation(source_mirrors.TypeMirror type,
+TypeMirror createInstantiation(TypeSourceMirror type,
List<TypeMirror> typeArguments) {
return type.createInstantiation(typeArguments);
}
@@ -18,6 +18,12 @@ TypeMirror createInstantiation(source_mirrors.TypeMirror type,
Future<MirrorSystem> analyze(String test) {
Uri repository = Platform.script.resolve('../../../../');
Uri testUri = repository.resolve('tests/lib/mirrors/$test');
+ return analyzeUri(testUri);
+}
+
+
+Future<MirrorSystem> analyzeUri(Uri testUri) {
+ Uri repository = Platform.script.resolve('../../../../');
Uri libraryRoot = repository.resolve('sdk/');
Uri packageRoot = Uri.base.resolve('${Platform.packageRoot}/');
var provider = new CompilerSourceFileProvider();
« no previous file with comments | « tests/compiler/dart2js/mirrors/mirrors_reader_test.dart ('k') | tests/lib/lib.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698