diff --git a/test/unit/CBot/CBot_test.cpp b/test/unit/CBot/CBot_test.cpp index 63c3e918..f130666f 100644 --- a/test/unit/CBot/CBot_test.cpp +++ b/test/unit/CBot/CBot_test.cpp @@ -647,6 +647,18 @@ TEST_F(CBotUT, FunctionRedefined) "}\n", CBotErrRedefFunc ); + + ExecuteTest( + "int func(int[] test)\n" + "{\n" + " return 1;\n" + "}\n" + "int func(int[] test)\n" + "{\n" + " return 2;\n" + "}\n", + CBotErrRedefFunc + ); } // TODO: Doesn't work @@ -845,6 +857,18 @@ TEST_F(CBotUT, ClassMethodRedefined) "}\n", CBotErrRedefFunc ); + + ExecuteTest( + "public class TestClass {\n" + " public int test(int[] test) {\n" + " return 1;\n" + " }\n" + " public int test(int[] test) {\n" + " return 2;\n" + " }\n" + "}\n", + CBotErrRedefFunc + ); } // TODO: Not only doesn't work but segfaults