Include package part name to top level closure names
#KT-4234 Fixed #KT-4496 Fixed
This commit is contained in:
@@ -102,7 +102,10 @@ public abstract class AbstractCheckLocalVariablesTableTest extends TestCaseWithT
|
||||
for (LocalVariable expectedVariable : expectedLocalVariables) {
|
||||
LocalVariable actualVariable = actualLocalVariables.get(index);
|
||||
assertEquals("Names are different", expectedVariable.name, actualVariable.name);
|
||||
assertEquals("Types are different for " + expectedVariable.name, expectedVariable.type, actualVariable.type);
|
||||
assertTrue(
|
||||
String.format("Type doesn't match regex: name %s, regex %s, type %s", expectedVariable.name, expectedVariable.type, actualVariable.type),
|
||||
actualVariable.type.matches(expectedVariable.type)
|
||||
);
|
||||
assertEquals("Indexes are different", expectedVariable.index, actualVariable.index);
|
||||
index++;
|
||||
}
|
||||
@@ -149,7 +152,7 @@ public abstract class AbstractCheckLocalVariablesTableTest extends TestCaseWithT
|
||||
|
||||
|
||||
expectedLocalVariables.add(new LocalVariable(nameMatcher.group(1),
|
||||
typeMatcher.group(1),
|
||||
StringUtil.escapeToRegexp(typeMatcher.group(1)).replace("\\*", ".+"),
|
||||
Integer.parseInt(indexMatcher.group(1))));
|
||||
}
|
||||
}
|
||||
|
||||
+6
@@ -1891,6 +1891,12 @@ public class BlackBoxWithStdlibCodegenTestGenerated extends AbstractBlackBoxCode
|
||||
JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/boxWithStdlib/reflection/enclosing"), Pattern.compile("^(.+)\\.kt$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("localClassInTopLevelFunction.kt")
|
||||
public void testLocalClassInTopLevelFunction() throws Exception {
|
||||
String fileName = JetTestUtils.navigationMetadata("compiler/testData/codegen/boxWithStdlib/reflection/enclosing/localClassInTopLevelFunction.kt");
|
||||
doTestWithStdlib(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/boxWithStdlib/reflection/enclosing/insideLambda")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(org.jetbrains.jet.JUnit3RunnerWithInners.class)
|
||||
|
||||
Reference in New Issue
Block a user