Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers...
[reactos.git] / rostests / apitests / winprint / main.c
diff --git a/rostests/apitests/winprint/main.c b/rostests/apitests/winprint/main.c
deleted file mode 100644 (file)
index 17f6af4..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * PROJECT:     ReactOS Standard Print Processor API Tests
- * LICENSE:     GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
- * PURPOSE:     Main functions
- * COPYRIGHT:   Copyright 2016 Colin Finck (colin@reactos.org)
- */
-
-#include <apitest.h>
-
-#define WIN32_NO_STATUS
-#include <windef.h>
-#include <winbase.h>
-#include <wingdi.h>
-#include <winspool.h>
-
-PVOID
-GetWinprintFunc(const char* FunctionName)
-{
-    DWORD cbNeeded;
-    HMODULE hWinprint;
-    PVOID pFunc;
-    WCHAR wszWinprintPath[MAX_PATH];
-
-    // Build the path to the default Print Processor winprint.dll in the Print Processor directory.
-    if (!GetPrintProcessorDirectoryW(NULL, NULL, 1, (LPBYTE)wszWinprintPath, sizeof(wszWinprintPath), &cbNeeded))
-    {
-        skip("Could not determine the path to the Print Processor directory, last error is %lu!\n", GetLastError());
-        return NULL;
-    }
-
-    wcscat(wszWinprintPath, L"\\winprint.dll");
-
-    // Try loading it.
-    hWinprint = LoadLibraryW(wszWinprintPath);
-    if (!hWinprint)
-    {
-        if (GetLastError() != ERROR_MOD_NOT_FOUND)
-        {
-            skip("LoadLibraryW failed for %S with error %lu!\n", wszWinprintPath, GetLastError());
-            return NULL;
-        }
-
-        // winprint.dll does not exist prior to NT6.
-        // The default Print Processor is implemented in localspl.dll instead.
-        hWinprint = LoadLibraryW(L"localspl.dll");
-        if (!hWinprint)
-        {
-            skip("LoadLibraryW failed for localspl.dll with error %lu!\n", GetLastError());
-            return NULL;
-        }
-    }
-
-    // Get the function we are looking for.
-    pFunc = GetProcAddress(hWinprint, FunctionName);
-    if (!pFunc)
-    {
-        skip("GetProcAddress failed for %s with error %lu!\n", FunctionName, GetLastError());
-        return NULL;
-    }
-    
-    return pFunc;
-}