Skip to content

Commit 421b6ce

Browse files
committed
Add test
1 parent 077d688 commit 421b6ce

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

language-server/test/dotty/tools/languageserver/DefinitionTest.scala

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,16 @@ class DefinitionTest {
3636
.definition(m5 to m6, List(m1 to m2))
3737
}
3838

39+
@Test def goToDefinitionImport: Unit = {
40+
withSources(
41+
code"""package a
42+
class ${m1}Foo${m2}""",
43+
code"""package b
44+
import a.${m3}Foo${m4}
45+
class C extends ${m5}Foo${m6}"""
46+
).definition(m1 to m2, List(m1 to m2))
47+
.definition(m3 to m4, List(m1 to m2))
48+
.definition(m5 to m6, List(m1 to m2))
49+
}
50+
3951
}

0 commit comments

Comments
 (0)