include_directories(../src/common)

function(qzion_test qzion_test_NAME qzion_test_SRCS qzion_test_MOCS)
    qt4_wrap_cpp(qzion_test_MOC_SRCS ${qzion_test_MOCS})
    add_executable(${qzion_test_NAME} ${qzion_test_SRCS} ${qzion_test_MOC_SRCS})
    target_link_libraries(${qzion_test_NAME} qzion ${QT_LIBRARIES})
endfunction(qzion_test)

add_subdirectory(clipper)
add_subdirectory(expedite)
add_subdirectory(simple)
add_subdirectory(zvalue)
add_subdirectory(text)
add_subdirectory(resize)

# copy data for tests
function(qzion_copy_data copy_data_FILENAME)
    configure_file(
        ${CMAKE_CURRENT_SOURCE_DIR}/${copy_data_FILENAME}
        ${CMAKE_CURRENT_BINARY_DIR}/${copy_data_FILENAME}
        COPYONLY
    )
endfunction(qzion_copy_data)

qzion_copy_data(images/bg.jpg)
qzion_copy_data(images/image.png)
qzion_copy_data(images/logo.png)
qzion_copy_data(images/square.png)

