[PATCH] gdi32/tests: Test writing to the default palette.
Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> --- Mostly to rule out one proposed reason for the ddraw test failures on Windows. dlls/gdi32/tests/palette.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/dlls/gdi32/tests/palette.c b/dlls/gdi32/tests/palette.c index 045f530..0043f55 100644 --- a/dlls/gdi32/tests/palette.c +++ b/dlls/gdi32/tests/palette.c @@ -142,6 +142,15 @@ static void test_palette_entries(void) ok(res == 1, "GetPaletteEntries should have returned 1 but returned %d\n", res); ok( palEntry.peFlags == getEntryResult.peFlags, "palEntry.peFlags (%#x) != getEntryResult.peFlags (%#x)\n", palEntry.peFlags, getEntryResult.peFlags ); + + /* Try setting the system palette */ + hpal = GetStockObject(DEFAULT_PALETTE); + res = SetPaletteEntries(hpal, 0, 1, &palEntry); + ok(!res, "SetPaletteEntries() should have failed\n"); + + res = GetPaletteEntries(hpal, 0, 1, &getEntryResult); + ok(res == 1, "GetPaletteEntries should have returned 1 but returned %d\n", res); + ok(memcmp(&palEntry, &getEntryResult, sizeof(PALETTEENTRY)), "entries should not match\n"); } static void test_halftone_palette(void) -- 2.7.4
participants (2)
-
Huw Davies -
Zebediah Figura