mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 04:13:34 +00:00
Add one more test for SetDCPenColor
svn path=/trunk/; revision=40307
This commit is contained in:
@@ -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);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user