comctl32/tests: Use EqualRect() instead of open coding it.
Signed-off-by: Michael Stefaniuc <mstefani@redhat.de> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
7f548e3f50
commit
fe9f23a2cb
|
@ -35,8 +35,8 @@ static HWND hMainWnd;
|
||||||
static int system_font_height;
|
static int system_font_height;
|
||||||
|
|
||||||
|
|
||||||
#define check_rect(name, val, exp) ok(val.top == exp.top && val.bottom == exp.bottom && \
|
#define check_rect(name, val, exp) ok(EqualRect(&val, &exp), \
|
||||||
val.left == exp.left && val.right == exp.right, "invalid rect (" name ") (%d,%d) (%d,%d) - expected (%d,%d) (%d,%d)\n", \
|
"invalid rect (" name ") (%d,%d) (%d,%d) - expected (%d,%d) (%d,%d)\n", \
|
||||||
val.left, val.top, val.right, val.bottom, exp.left, exp.top, exp.right, exp.bottom);
|
val.left, val.top, val.right, val.bottom, exp.left, exp.top, exp.right, exp.bottom);
|
||||||
|
|
||||||
#define check_rect_no_top(name, val, exp) { \
|
#define check_rect_no_top(name, val, exp) { \
|
||||||
|
|
|
@ -108,8 +108,8 @@ static const struct message restore_parent_seq[] = {
|
||||||
|
|
||||||
#define expect(EXPECTED,GOT) ok((GOT)==(EXPECTED), "Expected %d, got %d\n", (EXPECTED), (GOT))
|
#define expect(EXPECTED,GOT) ok((GOT)==(EXPECTED), "Expected %d, got %d\n", (EXPECTED), (GOT))
|
||||||
|
|
||||||
#define check_rect(name, val, exp, ...) ok(val.top == exp.top && val.bottom == exp.bottom && \
|
#define check_rect(name, val, exp, ...) ok(EqualRect(&val, &exp), \
|
||||||
val.left == exp.left && val.right == exp.right, "invalid rect (%d,%d) (%d,%d) - expected (%d,%d) (%d,%d) - (" name ")\n", \
|
"invalid rect (%d,%d) (%d,%d) - expected (%d,%d) (%d,%d) - (" name ")\n", \
|
||||||
val.left, val.top, val.right, val.bottom, exp.left, exp.top, exp.right, exp.bottom, __VA_ARGS__);
|
val.left, val.top, val.right, val.bottom, exp.left, exp.top, exp.right, exp.bottom, __VA_ARGS__);
|
||||||
|
|
||||||
#define compare(val, exp, format) ok((val) == (exp), #val " value " format " expected " format "\n", (val), (exp));
|
#define compare(val, exp, format) ok((val) == (exp), #val " value " format " expected " format "\n", (val), (exp));
|
||||||
|
|
Loading…
Reference in New Issue