Add Subsurface resources to tests

This way we can use the resources from within the tests, for example to
load XSLT files.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2015-03-14 18:04:53 -07:00
parent c28acce938
commit bf9460e55e

View file

@ -259,7 +259,7 @@ ADD_DEPENDENCIES(subsurface_generated_ui version)
ADD_DEPENDENCIES(subsurface_corelib version) ADD_DEPENDENCIES(subsurface_corelib version)
MACRO(test NAME FILE) MACRO(test NAME FILE)
ADD_EXECUTABLE(${NAME} tests/${FILE}) ADD_EXECUTABLE(${NAME} tests/${FILE} ${SUBSURFACE_RESOURCES})
TARGET_LINK_LIBRARIES(${NAME} subsurface_corelib ${QT_TEST_LIBRARIES} ${SUBSURFACE_LINK_LIBRARIES} -lzip -ldivecomputer) TARGET_LINK_LIBRARIES(${NAME} subsurface_corelib ${QT_TEST_LIBRARIES} ${SUBSURFACE_LINK_LIBRARIES} -lzip -ldivecomputer)
ADD_TEST(NAME ${NAME} COMMAND ${NAME}) ADD_TEST(NAME ${NAME} COMMAND ${NAME})
ENDMACRO() ENDMACRO()