Author: tkreuzer
Date: Thu Nov 29 02:45:23 2007
New Revision: 30849
URL:
http://svn.reactos.org/svn/reactos?rev=30849&view=rev
Log:
Another test for AddFontResourceEx
Modified:
trunk/rostests/apitests/gdi32api/tests/AddFontResourceEx.c
Modified: trunk/rostests/apitests/gdi32api/tests/AddFontResourceEx.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/gdi32api/tests/A…
==============================================================================
--- trunk/rostests/apitests/gdi32api/tests/AddFontResourceEx.c (original)
+++ trunk/rostests/apitests/gdi32api/tests/AddFontResourceEx.c Thu Nov 29 02:45:23 2007
@@ -4,6 +4,17 @@
Test_AddFontResourceEx(PTESTINFO pti)
{
WCHAR szFileName[MAX_PATH];
+
+ /* Test NULL filename */
+ SetLastError(ERROR_SUCCESS);
+ /* Windows crashes, would need SEH here */
+// TEST(AddFontResourceExW(NULL, 0, 0) != 0);
+// TEST(GetLastError() == ERROR_SUCCESS);
+
+ /* Test "" filename */
+ SetLastError(ERROR_SUCCESS);
+ TEST(AddFontResourceExW(L"", 0, 0) == 0);
+ TEST(GetLastError() == ERROR_INVALID_PARAMETER);
GetEnvironmentVariableW(L"systemroot", szFileName, MAX_PATH);
wcscat(szFileName, L"\\Fonts\\cour.ttf");