[PATCH] comctl32/tests: Use win_skip() for tests that should not be skipped on Wine

Nikolay Sivov nsivov at codeweavers.com
Tue Jan 24 17:31:00 CST 2017


Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
---
 dlls/comctl32/tests/datetime.c | 23 +++++++----------------
 dlls/comctl32/tests/header.c   |  2 +-
 dlls/comctl32/tests/monthcal.c |  2 +-
 dlls/comctl32/tests/mru.c      |  2 +-
 4 files changed, 10 insertions(+), 19 deletions(-)

diff --git a/dlls/comctl32/tests/datetime.c b/dlls/comctl32/tests/datetime.c
index 708921fec3..85fb94087e 100644
--- a/dlls/comctl32/tests/datetime.c
+++ b/dlls/comctl32/tests/datetime.c
@@ -527,23 +527,14 @@ static void test_dtm_set_and_get_system_time(void)
 {
     LRESULT r;
     SYSTEMTIME st, getSt, ref;
-    HWND hWnd, hWndDateTime_test_gdt_none;
-
-    hWndDateTime_test_gdt_none = create_datetime_control(0);
-
-    ok(hWndDateTime_test_gdt_none!=NULL, "Expected non NULL, got %p\n", hWndDateTime_test_gdt_none);
-    if(hWndDateTime_test_gdt_none) {
-        r = SendMessageA(hWndDateTime_test_gdt_none, DTM_SETSYSTEMTIME, GDT_NONE, (LPARAM)&st);
-        expect(0, r);
-    }
-    else {
-        skip("hWndDateTime_test_gdt_none is NULL\n");
-        flush_sequences(sequences, NUM_MSG_SEQUENCES);
+    HWND hWnd;
 
-        return;
-    }
+    hWnd = create_datetime_control(0);
+    ok(hWnd !=NULL, "Expected non NULL, got %p\n", hWnd);
+    r = SendMessageA(hWnd, DTM_SETSYSTEMTIME, GDT_NONE, (LPARAM)&st);
+    expect(0, r);
 
-    DestroyWindow(hWndDateTime_test_gdt_none);
+    DestroyWindow(hWnd);
 
     hWnd = create_datetime_control(DTS_SHOWNONE);
     flush_sequences(sequences, NUM_MSG_SEQUENCES);
@@ -797,7 +788,7 @@ START_TEST(datetime)
     pInitCommonControlsEx = (void*)GetProcAddress(hComctl32, "InitCommonControlsEx");
     if (!pInitCommonControlsEx)
     {
-        skip("InitCommonControlsEx() is missing. Skipping the tests\n");
+        win_skip("InitCommonControlsEx() is missing. Skipping the tests\n");
         return;
     }
     iccex.dwSize = sizeof(iccex);
diff --git a/dlls/comctl32/tests/header.c b/dlls/comctl32/tests/header.c
index 5c35b605f3..3ae83f8eee 100644
--- a/dlls/comctl32/tests/header.c
+++ b/dlls/comctl32/tests/header.c
@@ -1662,7 +1662,7 @@ static BOOL init(void)
     pInitCommonControlsEx = (void*)GetProcAddress(hComctl32, "InitCommonControlsEx");
     if (!pInitCommonControlsEx)
     {
-        skip("InitCommonControlsEx() is missing. Skipping the tests\n");
+        win_skip("InitCommonControlsEx() is missing. Skipping the tests\n");
         return FALSE;
     }
 
diff --git a/dlls/comctl32/tests/monthcal.c b/dlls/comctl32/tests/monthcal.c
index 30da089179..003a1ec6ac 100644
--- a/dlls/comctl32/tests/monthcal.c
+++ b/dlls/comctl32/tests/monthcal.c
@@ -2053,7 +2053,7 @@ START_TEST(monthcal)
     pInitCommonControlsEx = (void*)GetProcAddress(hComctl32, "InitCommonControlsEx");
     if (!pInitCommonControlsEx)
     {
-        skip("InitCommonControlsEx() is missing. Skipping the tests\n");
+        win_skip("InitCommonControlsEx() is missing. Skipping the tests\n");
         return;
     }
     iccex.dwSize = sizeof(iccex);
diff --git a/dlls/comctl32/tests/mru.c b/dlls/comctl32/tests/mru.c
index 5b5f98ede3..af49aba213 100644
--- a/dlls/comctl32/tests/mru.c
+++ b/dlls/comctl32/tests/mru.c
@@ -236,7 +236,7 @@ static void test_MRUListA(void)
 
     if (!pCreateMRUListA || !pFreeMRUList || !pAddMRUStringA || !pEnumMRUListA)
     {
-        skip("MRU entry points not found\n");
+        win_skip("MRU entry points not found\n");
         return;
     }
 
-- 
2.11.0




More information about the wine-patches mailing list