wlmaker
Loading...
Searching...
No Matches
test.h
Go to the documentation of this file.
1/* ========================================================================= */
20#ifndef __WLMTK_TEST_H__
21#define __WLMTK_TEST_H__
22
23#include <libbase/libbase.h>
24
25#ifdef __cplusplus
26extern "C" {
27#endif // __cplusplus
28
30#define WLMTK_TEST_VERIFY_WLRBOX_EQ(_test, _x, _y, _width, _height, _box) \
31 do { \
32 struct wlr_box __box = (_box); \
33 int __x = (_x), __y = (_y), __width = (_width), __height = (_height); \
34 if (__x != __box.x || __y != __box.y || \
35 __height != __box.height || __width != __box.width) { \
36 bs_test_fail_at( \
37 (_test), __FILE__, __LINE__, \
38 "Expecting {%d, %d, %d, %d}, got '%s' {%d, %d, %d, %d}", \
39 __x, __y, __width, __height, \
40 #_box, __box.x, __box.y, __box.width, __box.height); \
41 } \
42 } while (false)
43
44#ifdef __cplusplus
45} // extern "C"
46#endif // __cplusplus
47
48#endif /* __WLMTK_TEST_H__ */
49/* == End of test.h ================================================== */