Report full package FQ name in compilation errors related to visibility

#KT-18966 Fixed

GitOrigin-RevId: b56ffae526ead0b04d3763cdf4c714a7e0b0bf92
This commit is contained in:
Mikhail Zarechenskiy
2017-08-07 18:49:55 +03:00
committed by intellij-monorepo-bot
parent 1d7369f4a1
commit a9c0b4f8d3
4 changed files with 15 additions and 3 deletions
@@ -986,6 +986,12 @@ public class PsiCheckerTestGenerated extends AbstractPsiCheckerTest {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("idea/testData/checker/diagnosticsMessage"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.ANY, true);
}
@TestMetadata("fullPackageFQNameOnVisiblityError.kt")
public void testFullPackageFQNameOnVisiblityError() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("idea/testData/checker/diagnosticsMessage/fullPackageFQNameOnVisiblityError.kt");
doTest(fileName);
}
@TestMetadata("incompleteTypeArgumentList.kt")
public void testIncompleteTypeArgumentList() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("idea/testData/checker/diagnosticsMessage/incompleteTypeArgumentList.kt");
@@ -0,0 +1,6 @@
// WITH_RUNTIME
package a.b
@<error descr="[INVISIBLE_MEMBER] Cannot access 'InlineOnly': it is internal in 'kotlin.internal'">kotlin.internal.<error descr="[INVISIBLE_REFERENCE] Cannot access 'InlineOnly': it is internal in 'kotlin.internal'">InlineOnly</error></error>
inline fun foo() {}
@@ -15,7 +15,7 @@ fun access() {
publicInM1()
<error descr="[INVISIBLE_MEMBER] Cannot access 'privateInM1Test': it is private in file">privateInM1Test</error>()
<error descr="[INVISIBLE_MEMBER] Cannot access 'internalInM1Test': it is internal in 'test'">internalInM1Test</error>()
<error descr="[INVISIBLE_MEMBER] Cannot access 'internalInM1Test': it is internal in 'shared.test'">internalInM1Test</error>()
publicInM1Test()
<error descr="[INVISIBLE_MEMBER] Cannot access 'privateInM2': it is private in file">privateInM2</error>()
@@ -15,7 +15,7 @@ fun access() {
publicInM1()
<error descr="[INVISIBLE_MEMBER] Cannot access 'privateInM1Test': it is private in file">privateInM1Test</error>()
<error descr="[INVISIBLE_MEMBER] Cannot access 'internalInM1Test': it is internal in 'test'">internalInM1Test</error>()
<error descr="[INVISIBLE_MEMBER] Cannot access 'internalInM1Test': it is internal in 'shared.test'">internalInM1Test</error>()
publicInM1Test()
<error descr="[INVISIBLE_MEMBER] Cannot access 'privateInM2': it is private in file">privateInM2</error>()
@@ -23,7 +23,7 @@ fun access() {
publicInM2()
<error descr="[INVISIBLE_MEMBER] Cannot access 'privateInM2Test': it is private in file">privateInM2Test</error>()
<error descr="[INVISIBLE_MEMBER] Cannot access 'internalInM2Test': it is internal in 'test'">internalInM2Test</error>()
<error descr="[INVISIBLE_MEMBER] Cannot access 'internalInM2Test': it is internal in 'shared.test'">internalInM2Test</error>()
publicInM2Test()
<error descr="[INVISIBLE_MEMBER] Cannot access 'privateInM3': it is private in file">privateInM3</error>()