[ros-diffs] [jgardou] 48104: [W32KNAPI] - Add some more NtUserGetIconInfo tests

jgardou at svn.reactos.org jgardou at svn.reactos.org
Sun Jul 18 16:40:16 UTC 2010


Author: jgardou
Date: Sun Jul 18 16:40:15 2010
New Revision: 48104

URL: http://svn.reactos.org/svn/reactos?rev=48104&view=rev
Log:
[W32KNAPI]  - Add some more NtUserGetIconInfo tests

Modified:
    trunk/rostests/apitests/w32knapi/ntuser/NtUserGetIconInfo.c

Modified: trunk/rostests/apitests/w32knapi/ntuser/NtUserGetIconInfo.c
URL: http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntuser/NtUserGetIconInfo.c?rev=48104&r1=48103&r2=48104&view=diff
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntuser/NtUserGetIconInfo.c [iso-8859-1] (original)
+++ trunk/rostests/apitests/w32knapi/ntuser/NtUserGetIconInfo.c [iso-8859-1] Sun Jul 18 16:40:15 2010
@@ -99,5 +99,31 @@
 
 	DestroyIcon(hIcon);
 
+	/* Test full param, with foreign icon */
+	hIcon = LoadImageA(NULL,
+					   OIC_HAND,
+					   IMAGE_ICON,
+					   0,
+					   0,
+					   LR_DEFAULTSIZE);
+
+	TEST(hIcon != NULL);
+
+	RtlInitUnicodeString(&hInstStr, NULL);
+	RtlInitUnicodeString(&ResourceStr, NULL);
+
+	TEST(NtUserGetIconInfo(hIcon,
+						   &iinfo,
+						   &hInstStr,
+						   &ResourceStr,
+						   &bpp,
+						   FALSE) == TRUE);
+	
+	TESTX(hInstStr.Buffer == NULL, "hInstStr.buffer : %p\n", hInstStr.Buffer);
+	TEST((LPCTSTR)ResourceStr.Buffer == MAKEINTRESOURCE(IDI_ICON));
+	TEST(bpp == 32);
+
+	DestroyIcon(hIcon);
+
 	return APISTATUS_NORMAL;
 }




More information about the Ros-diffs mailing list