#ifndef COSMS_TEST #define COSMS_TEST #include #include #define COSMS_CORE_TEST_HEADER(test_module_name) printf("----------------------------------------\n%s\n----------------------------------------\n", test_module_name); #define COSMS_CORE_TEST_START(test_name) printf("[*] running test %s...\n", test_name) #define COSMS_CORE_TEST_SUCCESS(test_name) printf("[+] test %s completed successfully!\n", test_name); #define COSMS_CORE_TEST_FAIL(test_name, error) printf("[-] test %s failed with error: %s\n", test_name, error) inline bool cosms_core_test_assert(const char *test_name, bool expression, const char *error_message) { if (!expression) { printf("[-] test %s failed with error: %s\n", test_name, error_message); return false; } return true; } #endif