aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/CMakeLists.txt2
-rw-r--r--test/testFuncs1.c2
-rw-r--r--test/testFuncs2.c50
-rw-r--r--test/testFuncs2.h20
4 files changed, 72 insertions, 2 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index c60c3c7..9837520 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -1,3 +1,3 @@
cmake_minimum_required (VERSION 2.6)
project (tdd_test)
-add_executable(tddtest main.c testFuncs1.c)
+add_executable(tddtest main.c testFuncs1.c testFuncs2.c)
diff --git a/test/testFuncs1.c b/test/testFuncs1.c
index f721096..4312c79 100644
--- a/test/testFuncs1.c
+++ b/test/testFuncs1.c
@@ -1134,7 +1134,7 @@ void test32(void)
}
}
-static void test33(void)
+void test33(void)
{
short int a;
long int b;
diff --git a/test/testFuncs2.c b/test/testFuncs2.c
new file mode 100644
index 0000000..0bbc2ca
--- /dev/null
+++ b/test/testFuncs2.c
@@ -0,0 +1,50 @@
+
+#include "testFuncs2.h"
+
+static void test33(void)
+{
+ short int a;
+ long int b;
+
+ b = (int)a;
+}
+
+void testfunc1(void)
+{
+ unsigned char a;
+ unsigned char b;
+
+ b = a;
+}
+
+testfunc2(void)
+{
+ int a;
+ int b;
+ int sum;
+
+ sum = a + b;
+}
+
+void testfunc3()
+{
+ int a;
+ int b;
+ int c;
+
+ /*do stuff*/
+}
+
+int testfunc6(void)
+{
+ int a;
+ int b;
+ return ();
+}
+
+int testfunc7(void)
+{
+ int a;
+ int b;
+ return;
+} \ No newline at end of file
diff --git a/test/testFuncs2.h b/test/testFuncs2.h
new file mode 100644
index 0000000..e376c53
--- /dev/null
+++ b/test/testFuncs2.h
@@ -0,0 +1,20 @@
+
+extern int a[];
+
+extern int b[] = {1, 2, 3, 4, 5, 6};
+
+int c[2][3] = {1, 2, 3, 4, 5, 6};
+
+int d[2][3] = {{1, 2, 3}, {4, 5, 6}};
+
+static void test33(void);
+
+void testFunc4()
+{
+ /*do shit*/
+}
+
+testFunc5( void)
+{
+
+}