mirror of
https://github.com/reactos/reactos.git
synced 2025-04-17 19:27:00 +00:00
Add one more test for SetDCPenColor
svn path=/trunk/; revision=40307
This commit is contained in:
parent
189fc82964
commit
0bbce9519c
1 changed files with 11 additions and 0 deletions
|
@ -2,6 +2,7 @@ INT
|
|||
Test_SetDCPenColor(PTESTINFO pti)
|
||||
{
|
||||
HDC hScreenDC, hDC;
|
||||
HBITMAP hbmp;
|
||||
|
||||
// Test an incorrect DC
|
||||
SetLastError(ERROR_SUCCESS);
|
||||
|
@ -33,6 +34,16 @@ Test_SetDCPenColor(PTESTINFO pti)
|
|||
SetDCPenColor(hDC, CLR_INVALID);
|
||||
RTEST(SetDCPenColor(hDC, RGB(0,0,0)) == CLR_INVALID);
|
||||
|
||||
hbmp = CreateBitmap(10, 10, 1, 32, NULL);
|
||||
ASSERT(hbmp);
|
||||
|
||||
SelectObject(hDC, hbmp);
|
||||
SelectObject(hDC, GetStockObject(DC_PEN));
|
||||
SetDCPenColor(hDC, 0x123456);
|
||||
MoveToEx(hDC, 0, 0, NULL);
|
||||
LineTo(hDC, 10, 0);
|
||||
TEST(GetPixel(hDC, 5, 0) == 0x123456);
|
||||
|
||||
// Delete the DC
|
||||
DeleteDC(hDC);
|
||||
|
||||
|
|
Loading…
Reference in a new issue