Dmitry Timoshkov : gdiplus/tests: Print actual rectangle extents if the tests fail.

Alexandre Julliard julliard at winehq.org
Tue Sep 24 15:16:47 CDT 2013


Module: wine
Branch: master
Commit: fdeab06142ad6f21b43932740fa190af352ea78d
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=fdeab06142ad6f21b43932740fa190af352ea78d

Author: Dmitry Timoshkov <dmitry at baikal.ru>
Date:   Tue Sep 24 11:23:48 2013 +0900

gdiplus/tests: Print actual rectangle extents if the tests fail.

---

 dlls/gdiplus/tests/region.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/dlls/gdiplus/tests/region.c b/dlls/gdiplus/tests/region.c
index 3052f2e..ee6e158 100644
--- a/dlls/gdiplus/tests/region.c
+++ b/dlls/gdiplus/tests/region.c
@@ -86,7 +86,9 @@ static void verify_region(HRGN hrgn, const RECT *rc)
     {
         rect = (const RECT *)rgn.data.Buffer;
         trace("rect (%d,%d-%d,%d)\n", rect->left, rect->top, rect->right, rect->bottom);
-        ok(EqualRect(rect, rc), "rects don't match\n");
+        ok(EqualRect(rect, rc), "expected (%d,%d)-(%d,%d), got (%d,%d)-(%d,%d)\n",
+           rc->left, rc->top, rc->right, rc->bottom,
+           rect->left, rect->top, rect->right, rect->bottom);
     }
 
     ok(rgn.data.rdh.dwSize == sizeof(rgn.data.rdh), "expected sizeof(rdh), got %u\n", rgn.data.rdh.dwSize);
@@ -101,7 +103,9 @@ static void verify_region(HRGN hrgn, const RECT *rc)
         ok(rgn.data.rdh.nCount == 1, "expected 1, got %u\n", rgn.data.rdh.nCount);
         ok(rgn.data.rdh.nRgnSize == sizeof(RECT),  "expected sizeof(RECT), got %u\n", rgn.data.rdh.nRgnSize);
     }
-    ok(EqualRect(&rgn.data.rdh.rcBound, rc), "rects don't match\n");
+    ok(EqualRect(&rgn.data.rdh.rcBound, rc), "expected (%d,%d)-(%d,%d), got (%d,%d)-(%d,%d)\n",
+       rc->left, rc->top, rc->right, rc->bottom,
+       rgn.data.rdh.rcBound.left, rgn.data.rdh.rcBound.top, rgn.data.rdh.rcBound.right, rgn.data.rdh.rcBound.bottom);
 }
 
 static void test_getregiondata(void)




More information about the wine-cvs mailing list