Add script codegen tests with package statements

Tests codegen annotating visitor
This commit is contained in:
Pavel V. Talanov
2015-11-18 13:26:12 +03:00
parent ae5c95038b
commit bdc64f322c
3 changed files with 42 additions and 0 deletions
@@ -41,6 +41,12 @@ public class ScriptCodegenTestGenerated extends AbstractScriptCodegenTest {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/script"), Pattern.compile("^(.+)\\.kts$"), true);
}
@TestMetadata("classLiteralInsideFunction.kts")
public void testClassLiteralInsideFunction() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/script/classLiteralInsideFunction.kts");
doTest(fileName);
}
@TestMetadata("empty.kts")
public void testEmpty() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/script/empty.kts");
@@ -59,6 +65,12 @@ public class ScriptCodegenTestGenerated extends AbstractScriptCodegenTest {
doTest(fileName);
}
@TestMetadata("localFunction.kts")
public void testLocalFunction() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/script/localFunction.kts");
doTest(fileName);
}
@TestMetadata("outerCapture.kts")
public void testOuterCapture() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/script/outerCapture.kts");