tests added

This commit is contained in:
Denis Zharkov
2014-07-09 20:09:18 +04:00
committed by Alexander Udalov
parent e53e4fe257
commit 0f5e29df9b
22 changed files with 541 additions and 2 deletions
@@ -31,7 +31,7 @@ import org.jetbrains.jet.codegen.AbstractBytecodeTextTest;
/** This class is generated by {@link org.jetbrains.jet.generators.tests.TestsPackage}. DO NOT MODIFY MANUALLY */
@SuppressWarnings("all")
@TestMetadata("compiler/testData/codegen/bytecodeText")
@InnerTestClasses({BytecodeTextTestGenerated.Constants.class, BytecodeTextTestGenerated.DirectInvoke.class, BytecodeTextTestGenerated.Statements.class})
@InnerTestClasses({BytecodeTextTestGenerated.BoxingOptimization.class, BytecodeTextTestGenerated.Constants.class, BytecodeTextTestGenerated.DirectInvoke.class, BytecodeTextTestGenerated.Statements.class})
public class BytecodeTextTestGenerated extends AbstractBytecodeTextTest {
@TestMetadata("accessorForProtected.kt")
public void testAccessorForProtected() throws Exception {
@@ -152,6 +152,69 @@ public class BytecodeTextTestGenerated extends AbstractBytecodeTextTest {
doTest("compiler/testData/codegen/bytecodeText/traitImplGeneratedOnce.kt");
}
@TestMetadata("compiler/testData/codegen/bytecodeText/boxingOptimization")
public static class BoxingOptimization extends AbstractBytecodeTextTest {
public void testAllFilesPresentInBoxingOptimization() throws Exception {
JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), "org.jetbrains.jet.generators.tests.TestsPackage", new File("compiler/testData/codegen/bytecodeText/boxingOptimization"), Pattern.compile("^(.+)\\.kt$"), true);
}
@TestMetadata("casts.kt")
public void testCasts() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/casts.kt");
}
@TestMetadata("checkcastAndInstanceOf.kt")
public void testCheckcastAndInstanceOf() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/checkcastAndInstanceOf.kt");
}
@TestMetadata("fold.kt")
public void testFold() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/fold.kt");
}
@TestMetadata("nullCheck.kt")
public void testNullCheck() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/nullCheck.kt");
}
@TestMetadata("progressions.kt")
public void testProgressions() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/progressions.kt");
}
@TestMetadata("safeCallWithElvis.kt")
public void testSafeCallWithElvis() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/safeCallWithElvis.kt");
}
@TestMetadata("severalInlines.kt")
public void testSeveralInlines() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/severalInlines.kt");
}
@TestMetadata("simple.kt")
public void testSimple() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/simple.kt");
}
@TestMetadata("unsafeRemoving.kt")
public void testUnsafeRemoving() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/unsafeRemoving.kt");
}
@TestMetadata("variableClash.kt")
public void testVariableClash() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/variableClash.kt");
}
@TestMetadata("variables.kt")
public void testVariables() throws Exception {
doTest("compiler/testData/codegen/bytecodeText/boxingOptimization/variables.kt");
}
}
@TestMetadata("compiler/testData/codegen/bytecodeText/constants")
public static class Constants extends AbstractBytecodeTextTest {
public void testAllFilesPresentInConstants() throws Exception {
@@ -239,6 +302,7 @@ public class BytecodeTextTestGenerated extends AbstractBytecodeTextTest {
public static Test suite() {
TestSuite suite = new TestSuite("BytecodeTextTestGenerated");
suite.addTestSuite(BytecodeTextTestGenerated.class);
suite.addTestSuite(BoxingOptimization.class);
suite.addTestSuite(Constants.class);
suite.addTestSuite(DirectInvoke.class);
suite.addTestSuite(Statements.class);
@@ -31,7 +31,7 @@ import org.jetbrains.jet.codegen.generated.AbstractBlackBoxCodegenTest;
/** This class is generated by {@link org.jetbrains.jet.generators.tests.TestsPackage}. DO NOT MODIFY MANUALLY */
@SuppressWarnings("all")
@TestMetadata("compiler/testData/codegen/boxWithStdlib")
@InnerTestClasses({BlackBoxWithStdlibCodegenTestGenerated.Annotations.class, BlackBoxWithStdlibCodegenTestGenerated.Arrays.class, BlackBoxWithStdlibCodegenTestGenerated.CallableReference.class, BlackBoxWithStdlibCodegenTestGenerated.Casts.class, BlackBoxWithStdlibCodegenTestGenerated.DataClasses.class, BlackBoxWithStdlibCodegenTestGenerated.Evaluate.class, BlackBoxWithStdlibCodegenTestGenerated.FullJdk.class, BlackBoxWithStdlibCodegenTestGenerated.HashPMap.class, BlackBoxWithStdlibCodegenTestGenerated.JdkAnnotations.class, BlackBoxWithStdlibCodegenTestGenerated.PlatformNames.class, BlackBoxWithStdlibCodegenTestGenerated.Ranges.class, BlackBoxWithStdlibCodegenTestGenerated.Reflection.class, BlackBoxWithStdlibCodegenTestGenerated.Regressions.class, BlackBoxWithStdlibCodegenTestGenerated.Strings.class, BlackBoxWithStdlibCodegenTestGenerated.ToArray.class, BlackBoxWithStdlibCodegenTestGenerated.Vararg.class, BlackBoxWithStdlibCodegenTestGenerated.When.class})
@InnerTestClasses({BlackBoxWithStdlibCodegenTestGenerated.Annotations.class, BlackBoxWithStdlibCodegenTestGenerated.Arrays.class, BlackBoxWithStdlibCodegenTestGenerated.BoxingOptimization.class, BlackBoxWithStdlibCodegenTestGenerated.CallableReference.class, BlackBoxWithStdlibCodegenTestGenerated.Casts.class, BlackBoxWithStdlibCodegenTestGenerated.DataClasses.class, BlackBoxWithStdlibCodegenTestGenerated.Evaluate.class, BlackBoxWithStdlibCodegenTestGenerated.FullJdk.class, BlackBoxWithStdlibCodegenTestGenerated.HashPMap.class, BlackBoxWithStdlibCodegenTestGenerated.JdkAnnotations.class, BlackBoxWithStdlibCodegenTestGenerated.PlatformNames.class, BlackBoxWithStdlibCodegenTestGenerated.Ranges.class, BlackBoxWithStdlibCodegenTestGenerated.Reflection.class, BlackBoxWithStdlibCodegenTestGenerated.Regressions.class, BlackBoxWithStdlibCodegenTestGenerated.Strings.class, BlackBoxWithStdlibCodegenTestGenerated.ToArray.class, BlackBoxWithStdlibCodegenTestGenerated.Vararg.class, BlackBoxWithStdlibCodegenTestGenerated.When.class})
public class BlackBoxWithStdlibCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
public void testAllFilesPresentInBoxWithStdlib() throws Exception {
JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), "org.jetbrains.jet.generators.tests.TestsPackage", new File("compiler/testData/codegen/boxWithStdlib"), Pattern.compile("^(.+)\\.kt$"), true);
@@ -98,6 +98,59 @@ public class BlackBoxWithStdlibCodegenTestGenerated extends AbstractBlackBoxCode
}
@TestMetadata("compiler/testData/codegen/boxWithStdlib/boxingOptimization")
public static class BoxingOptimization extends AbstractBlackBoxCodegenTest {
public void testAllFilesPresentInBoxingOptimization() throws Exception {
JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), "org.jetbrains.jet.generators.tests.TestsPackage", new File("compiler/testData/codegen/boxWithStdlib/boxingOptimization"), Pattern.compile("^(.+)\\.kt$"), true);
}
@TestMetadata("casts.kt")
public void testCasts() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/casts.kt");
}
@TestMetadata("checkcastAndInstanceOf.kt")
public void testCheckcastAndInstanceOf() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/checkcastAndInstanceOf.kt");
}
@TestMetadata("fold.kt")
public void testFold() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/fold.kt");
}
@TestMetadata("nullCheck.kt")
public void testNullCheck() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/nullCheck.kt");
}
@TestMetadata("progressions.kt")
public void testProgressions() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/progressions.kt");
}
@TestMetadata("safeCallWithElvis.kt")
public void testSafeCallWithElvis() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/safeCallWithElvis.kt");
}
@TestMetadata("simple.kt")
public void testSimple() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/simple.kt");
}
@TestMetadata("unsafeRemoving.kt")
public void testUnsafeRemoving() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/unsafeRemoving.kt");
}
@TestMetadata("variables.kt")
public void testVariables() throws Exception {
doTestWithStdlib("compiler/testData/codegen/boxWithStdlib/boxingOptimization/variables.kt");
}
}
@TestMetadata("compiler/testData/codegen/boxWithStdlib/callableReference")
@InnerTestClasses({CallableReference.Function.class, CallableReference.Property.class})
public static class CallableReference extends AbstractBlackBoxCodegenTest {
@@ -1894,6 +1947,7 @@ public class BlackBoxWithStdlibCodegenTestGenerated extends AbstractBlackBoxCode
suite.addTestSuite(BlackBoxWithStdlibCodegenTestGenerated.class);
suite.addTestSuite(Annotations.class);
suite.addTestSuite(Arrays.class);
suite.addTestSuite(BoxingOptimization.class);
suite.addTest(CallableReference.innerSuite());
suite.addTestSuite(Casts.class);
suite.addTest(DataClasses.innerSuite());