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

Unified Diff: pkg/analyzer/test/src/summary/resynthesize_common.dart

Issue 2990523002: Parse documentation for class aliases, fix for /// comments. (Closed)
Patch Set: Created 3 years, 5 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: pkg/analyzer/test/src/summary/resynthesize_common.dart
diff --git a/pkg/analyzer/test/src/summary/resynthesize_common.dart b/pkg/analyzer/test/src/summary/resynthesize_common.dart
index 2a016706fc0fbeb0b69609fffbb638659619e5d3..62210ec99c5d7d73494ea131f51c30a043a9508e 100644
--- a/pkg/analyzer/test/src/summary/resynthesize_common.dart
+++ b/pkg/analyzer/test/src/summary/resynthesize_common.dart
@@ -1405,6 +1405,54 @@ class E {
test_class_alias_documented() async {
var library = await checkLibrary('''
+/**
+ * Docs
+ */
+class C = D with E;
+
+class D {}
+class E {}
+''');
+ checkElementText(library, r'''
+/**
+ * Docs
+ */
+class alias C extends D with E {
+ synthetic C() = D;
+}
+class D {
+}
+class E {
+}
+''');
+ }
+
+ test_class_alias_documented_tripleSlash() async {
+ var library = await checkLibrary('''
+/// aaa
+/// b
+/// cc
+class C = D with E;
+
+class D {}
+class E {}
+''');
+ checkElementText(library, r'''
+/// aaa
+/// b
+/// cc
+class alias C extends D with E {
+ synthetic C() = D;
+}
+class D {
+}
+class E {
+}
+''');
+ }
+
+ test_class_alias_documented_withLeadingNonDocumentation() async {
+ var library = await checkLibrary('''
// Extra comment so doc comment offset != 0
/**
* Docs

Powered by Google App Engine
This is Rietveld 408576698