[1/1]oleaut32: Fix Testcases on NT4 and lower
Wilfried Pasquazzo
wilfried.pasquazzo at gmail.com
Fri Oct 16 05:39:24 CDT 2009
A fix for my testcases of IPicture_Render method.
affected files: oleaut32/tests/olepicture.c
On older OS than Win2000 the testcase produces different results.
The method IPicture_Render isn't officially supported on those old OS,
therefore I just used the broken() statement with the results provided
by wines http://test.winehq.org/data/ to catch all of those errors.
Wilfried Pasquazzo
-------------- next part --------------
From 8be29a27dc1abade031426ab23cddab679f1a2c3 Mon Sep 17 00:00:00 2001
From: Wilfried Pasquazzo <wilfried.pasquazzo at gmail.com>
Date: Fri, 16 Oct 2009 12:32:02 +0200
Subject: [PATCH] Fix IPicture_Render tests for unsupported old OS
---
dlls/oleaut32/tests/olepicture.c | 15 ++++++++++-----
1 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/dlls/oleaut32/tests/olepicture.c b/dlls/oleaut32/tests/olepicture.c
index 42f58ae..491f83a 100644
--- a/dlls/oleaut32/tests/olepicture.c
+++ b/dlls/oleaut32/tests/olepicture.c
@@ -660,14 +660,19 @@ static void test_Render(void)
IPicture_Render(pic, hdc, 1, 1, 9, 9, 0, 0, pWidth, -pHeight, NULL);
+ /* broken results for some OS older than Win2k */
+ /* IPicture_Render isn't officially supported on those anyway */
result = GetPixel(hdc, 0, 0);
- ok(result == 0x00F0F0F0,
- "Color at 0,0 should be unchanged 0xF0F0F0, but was 0x%06X\n", result);
+ ok((result == 0x00F0F0F0) || /* Win2000,XP */
+ broken(result == 0x00F7F3F7), /* WinNT4 and lower */
+ "Color at 0,0 should be unchanged 0xF0F0F0, but was 0x%06X\n", result);
result = GetPixel(hdc, 5, 5);
- ok(result != 0x00F0F0F0,
- "Color at 5,5 should have changed, but still was 0x%06X\n", result);
+ ok(result != 0x00F0F0F0, /* Win2000,XP */
+ broken(result == 0x00F0F0F0), /* some Win9* */
+ "Color at 5,5 should have changed, but still was 0x%06X\n", result);
result = GetPixel(hdc, 10, 10);
- ok(result == 0x00F0F0F0,
+ ok(result == 0x00F0F0F0, /* Win2000,XP */
+ broken(result == 0x00F7F3F7), /* WinNT4 and lower */
"Color at 10,10 should be unchanged 0xF0F0F0, but was 0x%06X\n", result);
IPicture_Release(pic);
--
1.6.4.4
More information about the wine-patches
mailing list