Skip to content

Commit

Permalink
Do not build websocket tests if excluding websockets
Browse files Browse the repository at this point in the history
  • Loading branch information
ras0219 committed Dec 9, 2015
1 parent 61d14bf commit fa9f015
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 27 deletions.
26 changes: 14 additions & 12 deletions Release/tests/functional/websockets/client/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
include_directories(../utilities)
if (NOT CPPREST_EXCLUDE_WEBSOCKETS)
include_directories(../utilities)

set(SOURCES
authentication_tests.cpp
client_construction.cpp
close_tests.cpp
error_tests.cpp
receive_msg_tests.cpp
send_msg_tests.cpp
)

set(SOURCES
authentication_tests.cpp
client_construction.cpp
close_tests.cpp
error_tests.cpp
receive_msg_tests.cpp
send_msg_tests.cpp
)

add_casablanca_test(${LIB}websocketclient_test SOURCES)
target_link_libraries(${LIB}websocketclient_test ${LIB}websockettest_utilities)
add_casablanca_test(${LIB}websocketclient_test SOURCES)
target_link_libraries(${LIB}websocketclient_test ${LIB}websockettest_utilities)
endif()
34 changes: 19 additions & 15 deletions Release/tests/functional/websockets/utilities/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
include_directories(include)
if (NOT CPPREST_EXCLUDE_WEBSOCKETS)

if(WIN32)
add_definitions(-DWEBSOCKETTESTUTILITY_EXPORTS)
endif()
include_directories(include)

if(WIN32)
add_definitions(-DWEBSOCKETTESTUTILITY_EXPORTS)
endif()

set(SOURCES
test_websocket_server.cpp
)

add_library(${LIB}websockettest_utilities ${SOURCES})
target_link_libraries(${LIB}websockettest_utilities
${LIB}unittestpp
${LIB}common_utilities
${BOOST_LIBRARIES}
${Casablanca_LIBRARIES}
)

set(SOURCES
test_websocket_server.cpp
)

add_library(${LIB}websockettest_utilities ${SOURCES})
target_link_libraries(${LIB}websockettest_utilities
${LIB}unittestpp
${LIB}common_utilities
${BOOST_LIBRARIES}
${Casablanca_LIBRARIES}
)
endif()

0 comments on commit fa9f015

Please sign in to comment.