aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbloodstalker <thabogre@gmail.com>2016-11-24 15:22:37 +0000
committerbloodstalker <thabogre@gmail.com>2016-11-24 15:22:37 +0000
commitfb4c8a42c6fe9e6d94d07ae95a333aaecb769f84 (patch)
tree8f9292e12c500cd5b74936f847f1e50b79ff6a61
parentadded 12.4 and 12.5 (diff)
downloadmutator-fb4c8a42c6fe9e6d94d07ae95a333aaecb769f84.tar.gz
mutator-fb4c8a42c6fe9e6d94d07ae95a333aaecb769f84.zip
added tdd tests for 12.4 and 12.5
-rw-r--r--test/testFuncs1.c57
-rw-r--r--test/testFuncs1.h1
2 files changed, 58 insertions, 0 deletions
diff --git a/test/testFuncs1.c b/test/testFuncs1.c
index 2480afa..8c05582 100644
--- a/test/testFuncs1.c
+++ b/test/testFuncs1.c
@@ -4,6 +4,7 @@
/*include*/
/**********************************************************************************************************************/
#include "testFuncs1.h"
+//#include <string.h>
/**************************************************MACROS & DEFS*******************************************************/
/**********************************************************************************************************************/
@@ -836,5 +837,61 @@ void test17(void)
a = sizeof (b = 2000U);
}
+void test18(void)
+{
+ int a;
+ int b;
+ int c;
+ unsigned char d;
+
+ if (c && (a = b))
+ {
+ /*yada yada*/
+ }
+
+ if ((c = a) || a)
+ {
+ /*yada*/
+ }
+ if (c && (a || c))
+ {
+
+ }
+
+ d = c && (a = c);
+
+}
+
+void test19(void)
+{
+ const int a = 100;
+
+ unsigned char flag = 1;
+
+ unsigned char flag2;
+
+ unsigned char flag3;
+
+ //char *str = "loco\0";
+
+ const double pi = 3.54;
+
+ if ((flag) && pi)
+ {}
+
+ if (flag || flag2 && flag3)
+ {}
+
+ if (a == 0 && flag)
+ {}
+
+ if (flag || (a == 0))
+ {}
+
+ if (!flag || flag2)
+ {}
+
+}
+
/**********************************************************************************************************************/
/*the last line's been intentionally left blank.*/
diff --git a/test/testFuncs1.h b/test/testFuncs1.h
index ea5bb13..8457f87 100644
--- a/test/testFuncs1.h
+++ b/test/testFuncs1.h
@@ -114,6 +114,7 @@ void test10(void);
int test13(void);
void test15(void);
void test17(void);
+void test19(void);
/***********************************************************************************************************/
/*ive been intentionally left blank. dont touch me.*/