Browse Source

Split test programs to benchmarking and unit tests

They have very different purpose, so make things easier to work
with by having multiple directories.
tags/v1.9.90
Pierre Ossman 4 years ago
parent
commit
94de4dd0c4

+ 4
- 45
tests/CMakeLists.txt View File

@@ -1,46 +1,5 @@
include_directories(${FLTK_INCLUDE_DIR})
include_directories(${GETTEXT_INCLUDE_DIR})
# Benchmarking tools
add_subdirectory(perf)

include_directories(${CMAKE_SOURCE_DIR}/common)

add_library(test_util STATIC util.cxx)

add_executable(convperf convperf.cxx)
target_link_libraries(convperf test_util rfb)

add_executable(conv conv.cxx)
target_link_libraries(conv rfb)

add_executable(decperf decperf.cxx)
target_link_libraries(decperf test_util rfb)

add_executable(encperf encperf.cxx)
target_link_libraries(encperf test_util rfb)

add_executable(hostport hostport.cxx)
target_link_libraries(hostport rfb)

set(FBPERF_SOURCES
fbperf.cxx
../vncviewer/PlatformPixelBuffer.cxx
../vncviewer/Surface.cxx)
if(WIN32)
set(FBPERF_SOURCES ${FBPERF_SOURCES} ../vncviewer/Surface_Win32.cxx)
elseif(APPLE)
set(FBPERF_SOURCES
${FBPERF_SOURCES} ../vncviewer/Surface_OSX.cxx
${FBPERF_SOURCES} ../vncviewer/keysym2ucs.c
${FBPERF_SOURCES} ../vncviewer/cocoa.mm)
else()
set(FBPERF_SOURCES ${FBPERF_SOURCES} ../vncviewer/Surface_X11.cxx)
endif()
add_executable(fbperf ${FBPERF_SOURCES})
target_link_libraries(fbperf test_util rfb ${FLTK_LIBRARIES} ${GETTEXT_LIBRARIES})
if(WIN32)
target_link_libraries(fbperf msimg32)
endif()
if(APPLE)
target_link_libraries(fbperf "-framework Cocoa")
target_link_libraries(fbperf "-framework Carbon")
target_link_libraries(fbperf "-framework IOKit")
endif()
# Unit tests
add_subdirectory(unit)

+ 40
- 0
tests/perf/CMakeLists.txt View File

@@ -0,0 +1,40 @@
include_directories(${FLTK_INCLUDE_DIR})
include_directories(${GETTEXT_INCLUDE_DIR})

include_directories(${CMAKE_SOURCE_DIR}/common)

add_library(test_util STATIC util.cxx)

add_executable(convperf convperf.cxx)
target_link_libraries(convperf test_util rfb)

add_executable(decperf decperf.cxx)
target_link_libraries(decperf test_util rfb)

add_executable(encperf encperf.cxx)
target_link_libraries(encperf test_util rfb)

set(FBPERF_SOURCES
fbperf.cxx
${CMAKE_SOURCE_DIR}/vncviewer/PlatformPixelBuffer.cxx
${CMAKE_SOURCE_DIR}/vncviewer/Surface.cxx)
if(WIN32)
set(FBPERF_SOURCES ${FBPERF_SOURCES} ${CMAKE_SOURCE_DIR}/vncviewer/Surface_Win32.cxx)
elseif(APPLE)
set(FBPERF_SOURCES
${FBPERF_SOURCES} ${CMAKE_SOURCE_DIR}/vncviewer/Surface_OSX.cxx
${FBPERF_SOURCES} ${CMAKE_SOURCE_DIR}/vncviewer/keysym2ucs.c
${FBPERF_SOURCES} ${CMAKE_SOURCE_DIR}/vncviewer/cocoa.mm)
else()
set(FBPERF_SOURCES ${FBPERF_SOURCES} ${CMAKE_SOURCE_DIR}/vncviewer/Surface_X11.cxx)
endif()
add_executable(fbperf ${FBPERF_SOURCES})
target_link_libraries(fbperf test_util rfb ${FLTK_LIBRARIES} ${GETTEXT_LIBRARIES})
if(WIN32)
target_link_libraries(fbperf msimg32)
endif()
if(APPLE)
target_link_libraries(fbperf "-framework Cocoa")
target_link_libraries(fbperf "-framework Carbon")
target_link_libraries(fbperf "-framework IOKit")
endif()

tests/convperf.cxx → tests/perf/convperf.cxx View File


tests/decperf.cxx → tests/perf/decperf.cxx View File


tests/encperf.cxx → tests/perf/encperf.cxx View File


tests/fbperf.cxx → tests/perf/fbperf.cxx View File


tests/results/multicore/README → tests/perf/results/multicore/README View File


tests/results/multicore/multicore.ods → tests/perf/results/multicore/multicore.ods View File


tests/results/notrans/README → tests/perf/results/notrans/README View File


tests/results/notrans/armhf.csv → tests/perf/results/notrans/armhf.csv View File


tests/results/notrans/i386.csv → tests/perf/results/notrans/i386.csv View File


tests/results/notrans/x86_64.csv → tests/perf/results/notrans/x86_64.csv View File


tests/util.cxx → tests/perf/util.cxx View File


tests/util.h → tests/perf/util.h View File


+ 7
- 0
tests/unit/CMakeLists.txt View File

@@ -0,0 +1,7 @@
include_directories(${CMAKE_SOURCE_DIR}/common)

add_executable(conv conv.cxx)
target_link_libraries(conv rfb)

add_executable(hostport hostport.cxx)
target_link_libraries(hostport rfb)

tests/conv.cxx → tests/unit/conv.cxx View File


tests/hostport.cxx → tests/unit/hostport.cxx View File


Loading…
Cancel
Save