mirror of
https://github.com/reactos/reactos.git
synced 2024-08-28 14:18:41 +00:00
![Colin Finck](/assets/img/avatar_default.png)
Write an API-Test for localspl.dll. As the original localspl.dll from Windows Server 2003 relies on proper initialization inside spoolsv.exe, we cannot test it standalone as usual. To make testing possible anyway, this program basically does four things: - Injecting our testing code into spoolsv.exe. - Registering and running us as a service in the SYSTEM security context like spoolsv.exe, so that injection is possible at all. - Sending the test name and receiving the console output over named pipes. - Redirecting the received console output to stdout again, so it looks and feels like a standard API-Test. Nevertheless, the testing code in fpEnumPrinters.c is still written like a usual test. The known ok(), skip(), etc. macros can be used as usual, their output is just redirected through the named pipes. Thanks to Thomas for giving me the tip about injecting code into spoolsv! :) svn path=/branches/colins-printing-for-freedom/; revision=68080
14 lines
371 B
CMake
14 lines
371 B
CMake
|
|
add_subdirectory(dll)
|
|
|
|
list(APPEND SOURCE
|
|
service.c
|
|
tests.c
|
|
testlist.c)
|
|
|
|
add_executable(localspl_apitest ${SOURCE})
|
|
target_link_libraries(localspl_apitest wine ${PSEH_LIB})
|
|
set_module_type(localspl_apitest win32cui)
|
|
add_importlibs(localspl_apitest advapi32 winspool msvcrt kernel32 ntdll)
|
|
add_cd_file(TARGET localspl_apitest DESTINATION reactos/bin FOR all)
|