summaryrefslogtreecommitdiff
path: root/lib/igt_core.h
diff options
context:
space:
mode:
authorThomas Wood <thomas.wood@intel.com>2014-10-29 12:26:09 +0000
committerThomas Wood <thomas.wood@intel.com>2014-10-31 14:10:26 +0000
commite6228509664190a24cb1c22ac597ace8f79ecdd7 (patch)
tree718b0fc7b3c980f881f48e6b6da8e7b2ec3a92bb /lib/igt_core.h
parentd950f37be32a2bcf1a3da867bed3f9f397fb912d (diff)
lib/igt_core.h: add debug messages for test requirements
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
Diffstat (limited to 'lib/igt_core.h')
-rw-r--r--lib/igt_core.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/igt_core.h b/lib/igt_core.h
index 5318c5e9..f7a92ce9 100644
--- a/lib/igt_core.h
+++ b/lib/igt_core.h
@@ -199,7 +199,7 @@ void __igt_skip_check(const char *file, const int line,
const char *func, const char *check,
const char *format, ...) __attribute__((noreturn));
#define igt_skip_check(E, F...) \
- __igt_skip_check(__FILE__, __LINE__, __func__, E, F);
+ __igt_skip_check(__FILE__, __LINE__, __func__, E, F)
void igt_success(void);
void igt_fail(int exitcode) __attribute__((noreturn));
@@ -348,6 +348,7 @@ void igt_exit(void) __attribute__((noreturn));
*/
#define igt_require(expr) do { \
if (!(expr)) igt_skip_check(#expr , NULL); \
+ else igt_debug("Test requirement passed: "#expr"\n"); \
} while (0)
/**
@@ -362,6 +363,7 @@ void igt_exit(void) __attribute__((noreturn));
*/
#define igt_skip_on(expr) do { \
if ((expr)) igt_skip_check("!(" #expr ")" , NULL); \
+ else igt_debug("Test requirement passed: !("#expr")\n"); \
} while (0)
/**
@@ -380,6 +382,7 @@ void igt_exit(void) __attribute__((noreturn));
*/
#define igt_require_f(expr, f...) do { \
if (!(expr)) igt_skip_check(#expr , f); \
+ else igt_debug("Test requirement passed: "#expr"\n"); \
} while (0)
/**
@@ -398,6 +401,7 @@ void igt_exit(void) __attribute__((noreturn));
*/
#define igt_skip_on_f(expr, f...) do { \
if ((expr)) igt_skip_check("!("#expr")", f); \
+ else igt_debug("Test requirement passed: !("#expr")\n"); \
} while (0)
/* fork support code */