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

Unified Diff: pkg/analysis_server/test/analysis/get_hover_test.dart

Issue 1632033002: Issue 25542. If an element does not have its own documentation, use the documentation from the over… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 11 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/analysis_server/lib/src/computer/computer_overrides.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/test/analysis/get_hover_test.dart
diff --git a/pkg/analysis_server/test/analysis/get_hover_test.dart b/pkg/analysis_server/test/analysis/get_hover_test.dart
index cc1a4e47786f88267bad2c148274c7eea77a98b8..39e14e7c0fb5c26483f675bd7619fbe4b0f3f851 100644
--- a/pkg/analysis_server/test/analysis/get_hover_test.dart
+++ b/pkg/analysis_server/test/analysis/get_hover_test.dart
@@ -96,6 +96,36 @@ main() {
expect(hover.dartdoc, '''doc aaa\ndoc bbb''');
}
+ test_dartdoc_inherited_methodByMethod_fromInterface() async {
Brian Wilkerson 2016/01/25 22:09:59 I'll suggest a couple more tests. (1) Indirectly
scheglov 2016/01/26 00:52:50 Done.
scheglov 2016/01/26 00:52:50 Done.
+ addTestFile('''
+class A {
+ /// my doc
+ m() {} // in A
+}
+
+class B implements A {
+ m() {} // in B
+}
+''');
+ HoverInformation hover = await prepareHover('m() {} // in B');
+ expect(hover.dartdoc, '''my doc\n\nCopied from `A`.''');
+ }
+
+ test_dartdoc_inherited_methodByMethod_fromSuper() async {
+ addTestFile('''
+class A {
+ /// my doc
+ m() {} // in A
+}
+
+class B extends A {
+ m() {} // in B
+}
+''');
+ HoverInformation hover = await prepareHover('m() {} // in B');
+ expect(hover.dartdoc, '''my doc\n\nCopied from `A`.''');
+ }
+
test_enum() async {
addTestFile('''
enum MyEnum {AAA, BBB, CCC}
« no previous file with comments | « pkg/analysis_server/lib/src/computer/computer_overrides.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698