58 |
63 |
59 #define UCX_TEST_DECLARE(name) void name(UcxTestSuite*,FILE *); |
64 #define UCX_TEST_DECLARE(name) void name(UcxTestSuite*,FILE *); |
60 #define UCX_TEST_IMPLEMENT(name) void name(UcxTestSuite* _suite_,FILE *_output_) |
65 #define UCX_TEST_IMPLEMENT(name) void name(UcxTestSuite* _suite_,FILE *_output_) |
61 |
66 |
62 #define UCX_TEST_BEGIN fwrite("Running ", 1, 8, _output_);\ |
67 #define UCX_TEST_BEGIN fwrite("Running ", 1, 8, _output_);\ |
63 fwrite(__func__, 1, strlen(__func__), _output_);\ |
68 fwrite(__FUNCTION__, 1, strlen(__FUNCTION__), _output_);\ |
64 fwrite("... ", 1, 4, _output_);\ |
69 fwrite("... ", 1, 4, _output_);\ |
65 jmp_buf _env_; \ |
70 jmp_buf _env_; \ |
66 if (!setjmp(_env_)) { |
71 if (!setjmp(_env_)) { |
67 |
72 |
68 #define UCX_TEST_ASSERT(condition,message) if (!(condition)) { \ |
73 #define UCX_TEST_ASSERT(condition,message) if (!(condition)) { \ |