Author: gadamopoulos
Date: Fri Feb 10 00:00:28 2017
New Revision: 73767

URL: http://svn.reactos.org/svn/reactos?rev=73767&view=rev
Log:
[KERNEL32_APITESTS]: Add more tests for FindActCtxSectionStringW.

Added:
    trunk/rostests/apitests/kernel32/classtest2.manifest   (with props)
Modified:
    trunk/rostests/apitests/kernel32/CMakeLists.txt
    trunk/rostests/apitests/kernel32/FindActCtxSectionStringW.c

Modified: trunk/rostests/apitests/kernel32/CMakeLists.txt
URL: 
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/kernel32/CMakeLists.txt?rev=73767&r1=73766&r2=73767&view=diff
==============================================================================
--- trunk/rostests/apitests/kernel32/CMakeLists.txt     [iso-8859-1] (original)
+++ trunk/rostests/apitests/kernel32/CMakeLists.txt     [iso-8859-1] Fri Feb 10 
00:00:28 2017
@@ -33,6 +33,7 @@
 
 list(APPEND MANIFEST_FILES
     classtest.manifest
+    classtest2.manifest
     comctl32dep.manifest
     dep1.manifest
     deptest.manifest)

Modified: trunk/rostests/apitests/kernel32/FindActCtxSectionStringW.c
URL: 
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/kernel32/FindActCtxSectionStringW.c?rev=73767&r1=73766&r2=73767&view=diff
==============================================================================
--- trunk/rostests/apitests/kernel32/FindActCtxSectionStringW.c [iso-8859-1] 
(original)
+++ trunk/rostests/apitests/kernel32/FindActCtxSectionStringW.c [iso-8859-1] 
Fri Feb 10 00:00:28 2017
@@ -269,8 +269,8 @@
 
 START_TEST(FindActCtxSectionStringW)
 {
-    HANDLE h;
-    ULONG_PTR cookie;
+    HANDLE h, h2;
+    ULONG_PTR cookie, cookie2;
 
     /*First run the redirection tests without using our own actctx */
     TestClassRedirection(NULL, L"Button", L"Button", L"comctl32.dll", 27);
@@ -284,6 +284,9 @@
     {
         _ActivateCtx(h, &cookie, __LINE__);
         TestClassRedirection(h, L"Button", L"2.2.2.2!Button", L"testlib.dll", 
5);
+        _ActivateCtx(NULL, &cookie2, __LINE__);
+        TestClassRedirection(NULL, L"Button", L"Button", L"comctl32.dll", 27);
+        _DeactivateCtx(cookie2, __LINE__);
         _DeactivateCtx(cookie, __LINE__);
     }
     else
@@ -291,6 +294,23 @@
         skip("Failed to create context for classtest.manifest\n");
     }
     
+    /* Class redirection tests with multiple contexts in the activation stack 
*/
+    h2 = _CreateActCtxFromFile(L"classtest2.manifest", __LINE__);
+    if (h != INVALID_HANDLE_VALUE && h2 != INVALID_HANDLE_VALUE)
+    {
+        _ActivateCtx(h, &cookie, __LINE__);
+        _ActivateCtx(h2, &cookie2, __LINE__);
+        TestClassRedirection(NULL, L"Button", L"Button", L"comctl32.dll", 27);
+        TestClassRedirection(h2, L"MyClass", L"1.1.1.1!MyClass", 
L"testlib.dll", 5);
+        _DeactivateCtx(cookie2, __LINE__);
+        TestClassRedirection(h, L"Button", L"2.2.2.2!Button", L"testlib.dll", 
5);
+        _DeactivateCtx(cookie, __LINE__);
+    }
+    else
+    {
+        skip("Failed to create context for classtest.manifest\n");
+    }
+
     /* Dependency tests */
     h = _CreateActCtxFromFile(L"deptest.manifest", __LINE__);
     if (h != INVALID_HANDLE_VALUE)

Added: trunk/rostests/apitests/kernel32/classtest2.manifest
URL: 
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/kernel32/classtest2.manifest?rev=73767
==============================================================================
--- trunk/rostests/apitests/kernel32/classtest2.manifest        (added)
+++ trunk/rostests/apitests/kernel32/classtest2.manifest        [iso-8859-1] 
Fri Feb 10 00:00:28 2017
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+  <assemblyIdentity type="win32" name="ReactOS-TestLib" version="1.1.1.1" 
processorArchitecture="x86" publicKeyToken="6595b64144ccf1df"/>
+  <file name="testlib.dll">
+    <windowClass>ButtonListBox</windowClass>
+    <windowClass>ComboBoxEx32</windowClass>
+    <windowClass>ComboLBox</windowClass>
+    <windowClass>Combobox</windowClass>
+    <windowClass>MyClass</windowClass>
+  </file>
+</assembly>

Propchange: trunk/rostests/apitests/kernel32/classtest2.manifest
------------------------------------------------------------------------------
    svn:eol-style = CRLF


Reply via email to