Author: greatlrd
Date: Sat Jun 9 00:30:07 2007
New Revision: 27080
URL:
http://svn.reactos.org/svn/reactos?rev=27080&view=rev
Log:
last testcase for getavailmemory
Modified:
trunk/rostests/dxtest/ddraw/tests/CreateDDraw.cpp
Modified: trunk/rostests/dxtest/ddraw/tests/CreateDDraw.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/dxtest/ddraw/tests/Create…
==============================================================================
--- trunk/rostests/dxtest/ddraw/tests/CreateDDraw.cpp (original)
+++ trunk/rostests/dxtest/ddraw/tests/CreateDDraw.cpp Sat Jun 9 00:30:07 2007
@@ -332,21 +332,17 @@
Caps.dwCaps2 = DDSCAPS2_ADDITIONALPRIMARY;
TEST (DirectDraw->GetAvailableVidMem(&Caps, &Total, &Free) == DD_OK);
-
- // FIXME
- memset(&Caps,0,sizeof(DDSCAPS2));
- Caps.dwCaps3 = 0;
- TEST (DirectDraw->GetAvailableVidMem(&Caps, &Total, &Free) == DD_OK);
-
-
- /* dwCaps does not accpect any input param */
- memset(&Caps,0,sizeof(DDSCAPS2));
+ memset(&Caps,0,sizeof(DDSCAPS2));
+ Caps.dwCaps3 = ~(DDSCAPS3_MULTISAMPLE_QUALITY_MASK | DDSCAPS3_MULTISAMPLE_MASK |
DDSCAPS3_RESERVED1 | DDSCAPS3_RESERVED2 | DDSCAPS3_LIGHTWEIGHTMIPMAP |
DDSCAPS3_AUTOGENMIPMAP | DDSCAPS3_DMAP);
+ TEST (DirectDraw->GetAvailableVidMem(&Caps, &Total, &Free) ==
DDERR_INVALIDCAPS);
+
+ memset(&Caps,0,sizeof(DDSCAPS2));
+ Caps.dwCaps3 = (DDSCAPS3_MULTISAMPLE_QUALITY_MASK | DDSCAPS3_MULTISAMPLE_MASK |
DDSCAPS3_RESERVED1 | DDSCAPS3_RESERVED2 | DDSCAPS3_LIGHTWEIGHTMIPMAP |
DDSCAPS3_AUTOGENMIPMAP | DDSCAPS3_DMAP);
TEST (DirectDraw->GetAvailableVidMem(&Caps, &Total, &Free) == DD_OK);
memset(&Caps,0,sizeof(DDSCAPS2));
Caps.dwCaps4 = 1;
TEST (DirectDraw->GetAvailableVidMem(&Caps, &Total, &Free) ==
DDERR_INVALIDCAPS );
-
DirectDraw->Release();