set(TEST tst_client)
set(SOURCES
    tst_client.cpp
)

add_executable(${TEST} ${SOURCES})
include_directories(
    ${CMAKE_CURRENT_SOURCE_DIR}
    ${CMAKE_SOURCE_DIR}
    ${LomiriOnlineAccountsClient_SOURCE_DIR}/..
    ${LomiriOnlineAccountsUi_SOURCE_DIR}
)

target_link_libraries(${TEST}
    Qt${QT_VERSION}::Core
    Qt${QT_VERSION}::DBus
    Qt${QT_VERSION}::Test
    lomiri-online-accounts-client${LIB_SUFFIX}
)

add_test(${TEST} dbus-test-runner -t ${CMAKE_CURRENT_BINARY_DIR}/${TEST})
set_tests_properties(${TEST} PROPERTIES ENVIRONMENT QT_QPA_PLATFORM=minimal)
