]> git.meshlink.io Git - meshlink/blobdiff - test/blackbox/run_blackbox_tests/test_cases_open.c
Fix __warn_unused_result__, add more of it and fix the resulting warnings.
[meshlink] / test / blackbox / run_blackbox_tests / test_cases_open.c
index 2655376f55bd786ede08d582b5d6bc9316193c0e..40bd26c70103cd974a386b3c4531525289c55dc0 100644 (file)
     51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 */
 
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
+
 #include "execute_tests.h"
 #include "test_cases_open.h"
 #include "../common/containers.h"
@@ -87,7 +91,7 @@ static bool test_steps_mesh_open_01(void) {
        assert_int_not_equal(mesh, NULL);
 
        meshlink_close(mesh);
-       meshlink_destroy("open_conf");
+       assert(meshlink_destroy("open_conf"));
        return true;
 }
 
@@ -130,7 +134,7 @@ static bool test_steps_mesh_open_03(void) {
        meshlink_handle_t *mesh = meshlink_open("openconf", NULL, "test", DEV_CLASS_STATIONARY);
        assert_int_equal(mesh, NULL);
 
-       meshlink_destroy("open_conf");
+       assert(meshlink_destroy("open_conf"));
        return true;
 }
 
@@ -152,7 +156,7 @@ static bool test_steps_mesh_open_04(void) {
        meshlink_handle_t *mesh = meshlink_open("openconf", "foo", NULL, DEV_CLASS_STATIONARY);
        assert_int_equal(mesh, NULL);
 
-       meshlink_destroy("open_conf");
+       assert(meshlink_destroy("open_conf"));
        return true;
 }
 
@@ -174,7 +178,7 @@ static bool test_steps_mesh_open_05(void) {
        meshlink_handle_t *mesh = meshlink_open("openconf", "foo", "test", -1);
        assert_int_equal(mesh, NULL);
 
-       meshlink_destroy("open_conf");
+       assert(meshlink_destroy("open_conf"));
        return true;
 }