aboutsummaryrefslogtreecommitdiffstats
path: root/test/auto-refac-tdd/auto-refac-tdd01.c
diff options
context:
space:
mode:
authorbloodstalker <thabogre@gmail.com>2017-01-23 11:57:22 +0000
committerbloodstalker <thabogre@gmail.com>2017-01-23 11:57:22 +0000
commitbbe45e2ebb912752a6bd64438973eca73a8406d2 (patch)
tree04ddef62e2ed7e9fb654f4056b33a68a4d0fe51f /test/auto-refac-tdd/auto-refac-tdd01.c
parentadded an option to run automatic refactorings (diff)
downloadmutator-bbe45e2ebb912752a6bd64438973eca73a8406d2.tar.gz
mutator-bbe45e2ebb912752a6bd64438973eca73a8406d2.zip
added tdd tests for automatic refactoring
Diffstat (limited to 'test/auto-refac-tdd/auto-refac-tdd01.c')
-rw-r--r--test/auto-refac-tdd/auto-refac-tdd01.c49
1 files changed, 49 insertions, 0 deletions
diff --git a/test/auto-refac-tdd/auto-refac-tdd01.c b/test/auto-refac-tdd/auto-refac-tdd01.c
new file mode 100644
index 0000000..40e60d1
--- /dev/null
+++ b/test/auto-refac-tdd/auto-refac-tdd01.c
@@ -0,0 +1,49 @@
+
+/*first line's intentionally left blank.*/
+/**********************************************************************************************************************/
+/*inclusion directives*/
+#include "auto-refac-tdd01.h"
+/**********************************************************************************************************************/
+/**************************************************MACROS & DEFS*******************************************************/
+#define MACRO1 100U
+
+/**********************************************************************************************************************/
+/******************************************************Globals*********************************************************/
+
+
+/**********************************************************************************************************************/
+/***********************************************Function Definitions***************************************************/
+void tdd_forfixer(void)
+{
+ int loopcounter;
+ int counter;
+
+ for (loopcounter = 0; loopcounter < 10; ++loopcounter)
+ counter;
+
+ for (loopcounter = 0; loopcounter < 10; ++loopcounter)
+ counter-- ;
+}
+
+void tdd_ifconstswapper(void)
+{
+ int a;
+
+ if (a = 10)
+ {
+ /*blah blah*/
+ }
+
+ if (a == MACRO1)
+ {
+
+ }
+
+ if (MACRO1 == a)
+ {
+
+ }
+}
+/**********************************************************************************************************************/
+/**********************************************************************************************************************/
+/*last line's intntionally left blank.*/