summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxi <xi@18f92427-320e-0410-9341-c67f048884a3>2007-01-08 16:13:59 +0000
committerxi <xi@18f92427-320e-0410-9341-c67f048884a3>2007-01-08 16:13:59 +0000
commit183993927f9c928b5b60f8c9b8f9f199951a9b6b (patch)
tree9e85eb101c2113475447b18675ce0dca27603837
parent6e8d8c99d2953d928666dba43441454ebc0a0d00 (diff)
downloadlibyaml-183993927f9c928b5b60f8c9b8f9f199951a9b6b.tar.gz
Undefine the NDEBUG directive for the test programs.
git-svn-id: http://svn.pyyaml.org/libyaml/trunk@242 18f92427-320e-0410-9341-c67f048884a3
-rw-r--r--tests/run-dumper.c10
-rw-r--r--tests/run-emitter.c6
-rw-r--r--tests/run-loader.c4
-rw-r--r--tests/run-parser.c4
-rw-r--r--tests/run-scanner.c4
-rw-r--r--tests/test-reader.c4
-rw-r--r--tests/test-version.c4
7 files changed, 33 insertions, 3 deletions
diff --git a/tests/run-dumper.c b/tests/run-dumper.c
index 149dde0..41bead4 100644
--- a/tests/run-dumper.c
+++ b/tests/run-dumper.c
@@ -2,9 +2,13 @@
#include <stdlib.h>
#include <stdio.h>
-#include <assert.h>
#include <string.h>
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
+#include <assert.h>
+
#define BUFFER_SIZE 65536
#define MAX_DOCUMENTS 16
@@ -114,7 +118,9 @@ int compare_nodes(yaml_document_t *document1, int index1,
document2, node2->data.mapping.pairs.start[k].value)) return 0;
}
break;
-
+ default:
+ assert(0);
+ break;
}
return 1;
}
diff --git a/tests/run-emitter.c b/tests/run-emitter.c
index 0787895..6b246fa 100644
--- a/tests/run-emitter.c
+++ b/tests/run-emitter.c
@@ -2,9 +2,13 @@
#include <stdlib.h>
#include <stdio.h>
-#include <assert.h>
#include <string.h>
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
+#include <assert.h>
+
#define BUFFER_SIZE 65536
#define MAX_EVENTS 1024
diff --git a/tests/run-loader.c b/tests/run-loader.c
index a34ad07..8c36b66 100644
--- a/tests/run-loader.c
+++ b/tests/run-loader.c
@@ -2,6 +2,10 @@
#include <stdlib.h>
#include <stdio.h>
+
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
#include <assert.h>
int
diff --git a/tests/run-parser.c b/tests/run-parser.c
index 8c1a5db..1303112 100644
--- a/tests/run-parser.c
+++ b/tests/run-parser.c
@@ -2,6 +2,10 @@
#include <stdlib.h>
#include <stdio.h>
+
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
#include <assert.h>
int
diff --git a/tests/run-scanner.c b/tests/run-scanner.c
index 2c8d33e..2c79e7c 100644
--- a/tests/run-scanner.c
+++ b/tests/run-scanner.c
@@ -2,6 +2,10 @@
#include <stdlib.h>
#include <stdio.h>
+
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
#include <assert.h>
int
diff --git a/tests/test-reader.c b/tests/test-reader.c
index 49dc874..c6f84cd 100644
--- a/tests/test-reader.c
+++ b/tests/test-reader.c
@@ -5,6 +5,10 @@ yaml_parser_update_buffer(yaml_parser_t *parser, size_t length);
#include <stdlib.h>
#include <stdio.h>
+
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
#include <assert.h>
/*
diff --git a/tests/test-version.c b/tests/test-version.c
index 5982f7d..e3e4a16 100644
--- a/tests/test-version.c
+++ b/tests/test-version.c
@@ -2,6 +2,10 @@
#include <stdlib.h>
#include <stdio.h>
+
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
#include <assert.h>
int