diff options
Diffstat (limited to 'libkmstest')
-rw-r--r-- | libkmstest/test.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libkmstest/test.h b/libkmstest/test.h index fb51d29..2700024 100644 --- a/libkmstest/test.h +++ b/libkmstest/test.h @@ -13,6 +13,12 @@ abort(); \ } +#define FAIL(fmt, ...) \ + do { \ + fprintf(stderr, "%s:%d: %s:\n" fmt "\n", __FILE__, __LINE__, __PRETTY_FUNCTION__, ##__VA_ARGS__); \ + abort(); \ + } while(0) + #define FAIL_IF(x, fmt, ...) \ if (unlikely(x)) { \ fprintf(stderr, "%s:%d: %s:\n" fmt "\n", __FILE__, __LINE__, __PRETTY_FUNCTION__, ##__VA_ARGS__); \ |