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

Unified Diff: pkg/docgen/test/method_param_test.dart

Issue 263013006: Add function parameter info in docgen. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 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 | « pkg/docgen/lib/src/models/parameter.dart ('k') | pkg/docgen/test/multi_library_code/lib/test_lib2.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/docgen/test/method_param_test.dart
diff --git a/pkg/docgen/test/method_param_test.dart b/pkg/docgen/test/method_param_test.dart
new file mode 100644
index 0000000000000000000000000000000000000000..a12840e6b88c9fc4353078e0fd2c70d32a9516fb
--- /dev/null
+++ b/pkg/docgen/test/method_param_test.dart
@@ -0,0 +1,28 @@
+// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+library docgen.test.method_param;
+
+import 'package:path/path.dart' as path;
+import 'package:scheduled_test/scheduled_test.dart';
+
+import 'util.dart';
+import '../lib/docgen.dart' as gen;
+
+void main() {
+ test('method function parameters', () {
+ var lib_file = path.toUri(path.join(getMultiLibraryCodePath(), 'lib',
+ 'test_lib2.dart'));
+ return gen.getMirrorSystem([lib_file], false)
+ .then((mirrorSystem) {
+ var library = new gen.Library(mirrorSystem.libraries[lib_file]);
+
+ // Test that libraries do recursive exports correctly.
+ var funcParams = library.functions['fooFunc'].parameters;
+ expect('Symbol("dart.core.int")', library.functions['fooFunc']
+ .parameters['fooFuncParam'].functionDeclaration.parameters['x']
+ .type.mirror.qualifiedName.toString());
+ });
+ });
+}
« no previous file with comments | « pkg/docgen/lib/src/models/parameter.dart ('k') | pkg/docgen/test/multi_library_code/lib/test_lib2.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698