]> git.meshlink.io Git - meshlink/blobdiff - test/blackbox/run_blackbox_tests/test_cases_add_addr.c
Use blocking ADNS requests for most other hostname resolving.
[meshlink] / test / blackbox / run_blackbox_tests / test_cases_add_addr.c
index d9d456f378cb79e6ce56027277fcbf8d99d7c832..02453efda08450d9df411ac4d1805f53c2a81bf1 100644 (file)
     51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 */
 
+#ifdef NDEBUG
+#undef NDEBUG
+#endif
+
 #include "execute_tests.h"
 #include "test_cases_add_addr.h"
 #include "../common/containers.h"
@@ -68,7 +72,7 @@ static void test_case_mesh_add_address_01(void **state) {
 */
 static bool test_steps_mesh_add_address_01(void) {
        char *node = "foo";
-       meshlink_destroy("add_conf.1");
+       assert(meshlink_destroy("add_conf.1"));
 
        // Create node instance
        meshlink_handle_t *mesh = meshlink_open("add_conf.1", node, "chat", DEV_CLASS_STATIONARY);
@@ -96,7 +100,7 @@ static bool test_steps_mesh_add_address_01(void) {
 
        // Clean up
        meshlink_close(mesh);
-       meshlink_destroy("add_conf.1");
+       assert(meshlink_destroy("add_conf.1"));
        return true;
 }
 
@@ -137,7 +141,7 @@ static void test_case_mesh_add_address_03(void **state) {
     meshlink_add_address API returns false by reporting error successfully.
 */
 static bool test_steps_mesh_add_address_03(void) {
-       meshlink_destroy("add_conf.3");
+       assert(meshlink_destroy("add_conf.3"));
 
        // Create node instance
        meshlink_handle_t *mesh = meshlink_open("add_conf.3", "foo", "chat", DEV_CLASS_STATIONARY);
@@ -147,7 +151,7 @@ static bool test_steps_mesh_add_address_03(void) {
        assert_int_equal(result, false);
 
        meshlink_close(mesh);
-       meshlink_destroy("add_conf.3");
+       assert(meshlink_destroy("add_conf.3"));
        return true;
 }