File tree 1 file changed +31
-0
lines changed
pkg/analysis_server/test/lsp 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change @@ -36,6 +36,12 @@ class ImplementationTest extends AbstractLspAnalysisServerTest {
36
36
class /*[1*/C/*1]*/ extends A {}
37
37
''' );
38
38
39
+ Future <void > test_class_sub_underscore () => _testMarkedContent ('''
40
+ abstract class ^_ {}
41
+ class /*[0*/B/*0]*/ extends _ {}
42
+ class /*[1*/C/*1]*/ extends _ {}
43
+ ''' );
44
+
39
45
Future <void > test_class_subSub () => _testMarkedContent ('''
40
46
abstract class ^A {}
41
47
class /*[0*/B/*0]*/ extends A {}
@@ -68,6 +74,17 @@ class ImplementationTest extends AbstractLspAnalysisServerTest {
68
74
}
69
75
''' );
70
76
77
+ Future <void > test_getter_overriddenByField_underscore () =>
78
+ _testMarkedContent ('''
79
+ class B extends A {
80
+ final String? [!_!] = null;
81
+ }
82
+
83
+ abstract class A {
84
+ String? get _^;
85
+ }
86
+ ''' );
87
+
71
88
Future <void > test_method_excludesClassesWithoutImplementations () =>
72
89
_testMarkedContent ('''
73
90
abstract class A {
@@ -162,6 +179,20 @@ class ImplementationTest extends AbstractLspAnalysisServerTest {
162
179
}
163
180
''' );
164
181
182
+ Future <void > test_method_sub_underscore () => _testMarkedContent ('''
183
+ abstract class A {
184
+ void ^_();
185
+ }
186
+
187
+ class B extends A {
188
+ void /*[0*/_/*0]*/() {}
189
+ }
190
+
191
+ class C extends A {
192
+ void /*[1*/_/*1]*/() {}
193
+ }
194
+ ''' );
195
+
165
196
Future <void > test_method_subSub () => _testMarkedContent ('''
166
197
abstract class A {
167
198
void ^b();
You can’t perform that action at this time.
0 commit comments