test/dlist_tests.c

changeset 40
583718dd4cf3
parent 36
a9d656e4f7ce
child 69
fb59270b1de3
--- a/test/dlist_tests.c	Tue Oct 02 13:43:17 2012 +0200
+++ b/test/dlist_tests.c	Thu Oct 04 11:37:23 2012 +0200
@@ -8,12 +8,12 @@
     UcxDlist *list = ucx_dlist_append(NULL, "Hello");
     UCX_TEST_BEGIN
     
-    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed")
+    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed");
     
     list = ucx_dlist_append(list, " World!");
     
-    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed")
-    UCX_TEST_ASSERT(list->next->next == NULL, "failed")
+    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed");
+    UCX_TEST_ASSERT(list->next->next == NULL, "failed");
     UCX_TEST_END
     
     ucx_dlist_free(list);
@@ -25,9 +25,9 @@
 
     list = ucx_dlist_prepend(list, "Hello");
     
-    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed")
-    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed")
-    UCX_TEST_ASSERT(list->next->next == NULL, "failed")
+    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed");
+    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed");
+    UCX_TEST_ASSERT(list->next->next == NULL, "failed");
     
     UCX_TEST_END
     ucx_dlist_free(list);
@@ -42,8 +42,8 @@
     list3 = ucx_dlist_prepend(list3, "Hallo");
     UCX_TEST_BEGIN
     
-    UCX_TEST_ASSERT(ucx_dlist_equals(list, list2, cmp_string, NULL), "failed")
-    UCX_TEST_ASSERT(!ucx_dlist_equals(list, list3, cmp_string, NULL), "failed")
+    UCX_TEST_ASSERT(ucx_dlist_equals(list, list2, cmp_string, NULL), "failed");
+    UCX_TEST_ASSERT(!ucx_dlist_equals(list, list3, cmp_string, NULL), "failed");
     
     UCX_TEST_END
     ucx_dlist_free(list3);
@@ -58,9 +58,9 @@
     
     list = ucx_dlist_concat(list, list2);
     
-    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed")
-    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed")
-    UCX_TEST_ASSERT(list->next->next == NULL, "failed")
+    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed");
+    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed");
+    UCX_TEST_ASSERT(list->next->next == NULL, "failed");
     
     UCX_TEST_END
     ucx_dlist_free(list);
@@ -130,9 +130,9 @@
     
     list = ucx_dlist_remove(list, ucx_dlist_get(list, 1));
     
-    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed")
-    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed")
-    UCX_TEST_ASSERT(list->next->next == NULL, "failed")
+    UCX_TEST_ASSERT(strncmp(list->data, "Hello", 5) == 0, "failed");
+    UCX_TEST_ASSERT(strncmp(list->next->data, " World!", 7) == 0, "failed");
+    UCX_TEST_ASSERT(list->next->next == NULL, "failed");
     
     UCX_TEST_END
     ucx_dlist_free(list);
@@ -152,9 +152,9 @@
     UcxDlist *copy = ucx_dlist_clone(list, copy_string, NULL);
     UCX_TEST_BEGIN
 
-    UCX_TEST_ASSERT(ucx_dlist_equals(list, copy, cmp_string, NULL), "failed")
-    UCX_TEST_ASSERT(hello != copy->data, "first element is no copy")
-    UCX_TEST_ASSERT(world != copy->next->data, "second element is no copy")
+    UCX_TEST_ASSERT(ucx_dlist_equals(list, copy, cmp_string, NULL), "failed");
+    UCX_TEST_ASSERT(hello != copy->data, "first element is no copy");
+    UCX_TEST_ASSERT(world != copy->next->data, "second element is no copy");
 
     UCX_TEST_END
     free(copy->next->data);

mercurial