Commit ff8d709f authored by Wieland Morgenstern's avatar Wieland Morgenstern

label lib unit tests as `gpu` if they need a GPU to run

parent b241644b
...@@ -33,8 +33,13 @@ endif(WINDOWS) ...@@ -33,8 +33,13 @@ endif(WINDOWS)
get_filename_component(TEST_SRC_PATH . ABSOLUTE) get_filename_component(TEST_SRC_PATH . ABSOLUTE)
# All trailing arguments are libs to link # All trailing arguments are libs to link
function(add_vs_unit_test test_name test_file) function(add_vs_lib_test test_name test_file)
add_vs_test_arg(${test_name} ${test_file} "unit" "" ${ARGN}) add_vs_test_arg(${test_name} ${test_file} "lib" "" ${ARGN})
endfunction()
# tests requiring a GPU to run
function(add_vs_lib_gpu_test test_name test_file)
add_vs_test_arg(${test_name} ${test_file} "lib gpu" "" ${ARGN})
endfunction() endfunction()
# All trailing arguments are libs to link # All trailing arguments are libs to link
...@@ -88,64 +93,69 @@ endfunction() ...@@ -88,64 +93,69 @@ endfunction()
if(STAGING) if(STAGING)
# XXX: ADD HERE NEW TESTS # XXX: ADD HERE NEW TESTS
else(STAGING) else(STAGING)
add_vs_unit_test(AffineTest affineTest.cpp) add_vs_lib_test(AffineTest affineTest.cpp)
add_vs_unit_test(AmbisonicTest ambisonicTest.cpp) add_vs_lib_test(AmbisonicTest ambisonicTest.cpp)
add_vs_unit_test(AudioDelayTest audioDelayTest.cpp) add_vs_lib_test(AudioDelayTest audioDelayTest.cpp)
add_vs_unit_test(AudioFilterTest audioFilterTest.cpp) add_vs_lib_test(AudioFilterTest audioFilterTest.cpp)
add_vs_unit_test(AudioSampleConvertTest audioSampleConvertTest.cpp) add_vs_lib_test(AudioSampleConvertTest audioSampleConvertTest.cpp)
add_vs_unit_test(AudioToolsTest audioToolsTest.cpp) add_vs_lib_test(AudioToolsTest audioToolsTest.cpp)
add_vs_unit_test(AutoCropTest autoCropTest.cpp) add_vs_lib_test(AutoCropTest autoCropTest.cpp)
add_vs_unit_test(Base64Test base64Test.cpp) add_vs_lib_test(Base64Test base64Test.cpp)
add_vs_unit_test(BijectiveTransformTest bijectiveTransformTest.cpp) add_vs_lib_test(BijectiveTransformTest bijectiveTransformTest.cpp)
add_vs_unit_test(BufferedReaderTest bufferedReaderTest.cpp) add_vs_lib_test(CalibrationResetTest calibrationResetTest.cpp)
add_vs_unit_test(BufferTest bufferTest.cpp) add_vs_lib_test(CalibrationWithTranslationTest calibrationWithTranslationTest.cpp)
add_vs_unit_test(CalibrationResetTest calibrationResetTest.cpp) add_vs_lib_test(CircularBufferTest circularBufferTest.cpp)
add_vs_unit_test(CalibrationWithTranslationTest calibrationWithTranslationTest.cpp) add_vs_lib_test(ControlPointsConnectivityTest controlPointsConnectivityTest.cpp)
add_vs_unit_test(ControllerInputFramesTest controllerInputFramesTest.cpp) add_vs_lib_test(CropAreaLensCenterTest cropAreaLensCenterTest.cpp)
add_vs_unit_test(ControlPointsConnectivityTest controlPointsConnectivityTest.cpp) add_vs_lib_test(CurveTest curveTest.cpp)
add_vs_unit_test(CropAreaLensCenterTest cropAreaLensCenterTest.cpp) add_vs_lib_test(FrameRateTest frameRateTest.cpp)
add_vs_unit_test(CurveTest curveTest.cpp) add_vs_lib_test(HostTransformTest hostTransformTest.cpp)
add_vs_unit_test(DrawNumberTest drawNumberTest.cpp) add_vs_lib_test(IMUStabilizationTest imuStabilizationTest.cpp)
add_vs_unit_test(FrameRateTest frameRateTest.cpp) add_vs_lib_test(LogTest logTest.cpp)
add_vs_unit_test(GridTest gridTest.cpp) add_vs_lib_test(MetadataExposureTest metadataExposureTest.cpp)
add_vs_unit_test(HostTransformTest hostTransformTest.cpp) add_vs_lib_test(MetadataToneCurveTest metadataToneCurveTest.cpp)
add_vs_unit_test(IMUStabilizationTest imuStabilizationTest.cpp) add_vs_lib_test(MutexTest mutexTest.cpp)
add_vs_unit_test(InputTest inputTest.cpp) add_vs_lib_test(OptimalPanoSizeTest optimalPanoSizeTest.cpp)
add_vs_unit_test(LogTest logTest.cpp) add_vs_lib_test(OutputEventManagerTest outputEventManagerTest.cpp)
add_vs_unit_test(MetadataExposureTest metadataExposureTest.cpp) add_vs_lib_test(PanoRigCompatibleTest panoRigCompatibleTest.cpp)
add_vs_unit_test(MetadataToneCurveTest metadataToneCurveTest.cpp) add_vs_lib_test(PanoUpdaterTest panoUpdaterTest.cpp)
add_vs_unit_test(MutexTest mutexTest.cpp) add_vs_lib_test(ParsingTest parsingTest.cpp)
add_vs_unit_Test(OptimalPanoSizeTest optimalPanoSizeTest.cpp) add_vs_lib_test(ProceduralTest proceduralTest.cpp)
add_vs_unit_test(OutputEventManagerTest outputEventManagerTest.cpp) add_vs_lib_test(PtsCommaParsingTest ptsCommaParsingTest.cpp)
add_vs_unit_test(PanoRigCompatibleTest panoRigCompatibleTest.cpp) add_vs_lib_test(PtsParsingTest ptsParsingTest.cpp)
add_vs_unit_test(PanoUpdaterTest panoUpdaterTest.cpp) add_vs_lib_test(PtvAudioPipeTest ptvAudioPipeTest.cpp)
add_vs_unit_test(ParsingTest parsingTest.cpp) add_vs_lib_test(PtvEquirectInputSerializeTest ptvEquirectInputSerializeTest.cpp)
add_vs_unit_test(ProceduralTest proceduralTest.cpp) add_vs_lib_test(PtvTest ptvTest.cpp)
add_vs_unit_test(PtsCommaParsingTest ptsCommaParsingTest.cpp) add_vs_lib_test(RectTest rectTest.cpp)
add_vs_unit_test(PtsParsingTest ptsParsingTest.cpp) add_vs_lib_test(RemoveInputTest removeInputTest.cpp)
add_vs_unit_test(PtvAudioPipeTest ptvAudioPipeTest.cpp) add_vs_lib_test(ResetInputGeometryTest resetInputGeometryTest.cpp)
add_vs_unit_test(PtvDefaultsTest ptvDefaultsTest.cpp) add_vs_lib_test(RigDefTest rigDefTest.cpp)
add_vs_unit_test(PtvEquirectInputSerializeTest ptvEquirectInputSerializeTest.cpp) add_vs_lib_test(RotationTest rotationTest.cpp)
add_vs_unit_test(PtvTest ptvTest.cpp) add_vs_lib_test(StabFilterTest stabFilterTest.cpp)
add_vs_unit_test(ReaderControllerTest readerControllerTest.cpp) add_vs_lib_test(StatusTest statusTest.cpp)
add_vs_unit_test(RectTest rectTest.cpp) add_vs_lib_test(ThreadPoolTest threadPoolTest.cpp)
add_vs_unit_test(RemoveInputTest removeInputTest.cpp) add_vs_lib_test(TransformStackTest transformStackTest.cpp)
add_vs_unit_test(ResetInputGeometryTest resetInputGeometryTest.cpp) add_vs_lib_test(UkfQuaternionTest ukfQuaternionTest.cpp)
add_vs_unit_test(RigDefTest rigDefTest.cpp)
add_vs_unit_test(RotationTest rotationTest.cpp) add_vs_lib_gpu_test(BufferedReaderTest bufferedReaderTest.cpp)
add_vs_unit_test(SimpleKernelTest simpleKernelTest.cpp) add_vs_lib_gpu_test(BufferTest bufferTest.cpp)
add_vs_unit_test(StabFilterTest stabFilterTest.cpp) add_vs_lib_gpu_test(ControllerInputFramesTest controllerInputFramesTest.cpp)
add_vs_unit_test(StatusTest statusTest.cpp) add_vs_lib_gpu_test(DrawNumberTest drawNumberTest.cpp)
add_vs_unit_test(StitchOutputTest stitchOutputTest.cpp) add_vs_lib_gpu_test(GridTest gridTest.cpp)
add_vs_unit_test(StreamTest streamTest.cpp) add_vs_lib_gpu_test(InputTest inputTest.cpp)
add_vs_unit_test(UndistortTest undistortTest.cpp) add_vs_lib_gpu_test(PtvDefaultsTest ptvDefaultsTest.cpp)
add_vs_lib_gpu_test(ReaderControllerTest readerControllerTest.cpp)
add_vs_lib_gpu_test(SimpleKernelTest simpleKernelTest.cpp)
add_vs_lib_gpu_test(StitchOutputTest stitchOutputTest.cpp)
add_vs_lib_gpu_test(StreamTest streamTest.cpp)
add_vs_lib_gpu_test(UndistortTest undistortTest.cpp)
if(NOT (LINUX AND ${GPU_BACKEND_DEFAULT} STREQUAL OPENCL)) if(NOT (LINUX AND ${GPU_BACKEND_DEFAULT} STREQUAL OPENCL))
add_vs_unit_test(MappingTest mappingTest.cpp) add_vs_lib_gpu_test(MappingTest mappingTest.cpp)
endif() endif()
if(NOT OCLGRIND) if(NOT OCLGRIND)
add_vs_unit_test(ControllerTest controllerTest.cpp) add_vs_lib_gpu_test(ControllerTest controllerTest.cpp)
endif() endif()
# removes the cache dir which is used by other tests # removes the cache dir which is used by other tests
...@@ -167,46 +177,41 @@ else(STAGING) ...@@ -167,46 +177,41 @@ else(STAGING)
add_vs_test_arg(CompressionTest compressionTest.cpp "cmd" "") add_vs_test_arg(CompressionTest compressionTest.cpp "cmd" "")
# can't run in parallel # can't run in parallel
add_vs_test_arg(ReaderControllerAsyncTest readerControllerAsyncTest.cpp "cmd" "") add_vs_test_arg(ReaderControllerAsyncTest readerControllerAsyncTest.cpp "cmd gpu" "")
if(NOT LINUX OR ${GPU_BACKEND_DEFAULT} STREQUAL CUDA) if(NOT LINUX OR ${GPU_BACKEND_DEFAULT} STREQUAL CUDA)
# VSA-7248 # VSA-7248
add_vs_unit_test(UnpackTest unpackTest.cpp) add_vs_lib_gpu_test(UnpackTest unpackTest.cpp)
add_vs_unit_test(VoronoiTest voronoiTest.cpp) add_vs_lib_gpu_test(VoronoiTest voronoiTest.cpp)
endif() endif()
if((${GPU_BACKEND_DEFAULT} STREQUAL CUDA OR NOT WINDOWS) AND NOT OCLGRIND) if((${GPU_BACKEND_DEFAULT} STREQUAL CUDA OR NOT WINDOWS) AND NOT OCLGRIND)
add_vs_unit_test(SynchroTest synchroTest.cpp) add_vs_lib_gpu_test(SynchroTest synchroTest.cpp)
endif() endif()
add_vs_unit_test(ThreadPoolTest threadPoolTest.cpp)
add_vs_unit_test(TransformStackTest transformStackTest.cpp)
add_vs_unit_test(UkfQuaternionTest ukfQuaternionTest.cpp)
add_vs_unit_test(CircularBufferTest circularBufferTest.cpp)
if(NOT APPLE) if(NOT APPLE)
# this test is not working on the mac Nvidia buildbot # this test is not working on the mac Nvidia buildbot
# a known problem already in the Scons test # a known problem already in the Scons test
add_vs_unit_test(UtilTest utilTest.cpp) add_vs_lib_test(UtilTest utilTest.cpp)
endif(NOT APPLE) endif(NOT APPLE)
if(${GPU_BACKEND_DEFAULT} STREQUAL CUDA) if(${GPU_BACKEND_DEFAULT} STREQUAL CUDA)
# add_vs_unit_test(BlurRGBA210Test blurRGBA210Test.cpp) # add_vs_lib_test(BlurRGBA210Test blurRGBA210Test.cpp)
add_vs_unit_test(BlurTest blurTest.cpp) add_vs_lib_gpu_test(BlurTest blurTest.cpp)
add_vs_unit_test(DownsamplingTest downsamplingTest.cpp) add_vs_lib_gpu_test(DownsamplingTest downsamplingTest.cpp)
add_vs_unit_test(FlowBasedBlendingTest flowBasedBlendingTest.cpp) add_vs_lib_gpu_test(FlowBasedBlendingTest flowBasedBlendingTest.cpp)
add_vs_unit_test(HistogramTest histogramTest.cpp) add_vs_lib_gpu_test(HistogramTest histogramTest.cpp)
add_vs_unit_test(PyramidTest pyramidTest.cpp) add_vs_lib_gpu_test(PyramidTest pyramidTest.cpp)
add_vs_unit_test(ReduceTest reduceTest.cpp) add_vs_lib_gpu_test(ReduceTest reduceTest.cpp)
add_vs_unit_test(RenderTest renderTest.cpp) add_vs_lib_gpu_test(RenderTest renderTest.cpp)
add_vs_unit_test(SamplingTest samplingTest.cpp) add_vs_lib_gpu_test(SamplingTest samplingTest.cpp)
add_vs_unit_test(SeamTest seamTest.cpp) add_vs_lib_gpu_test(SeamTest seamTest.cpp)
add_vs_unit_test(SpaceTransformTest spaceTransformTest.cpp) add_vs_lib_gpu_test(SpaceTransformTest spaceTransformTest.cpp)
add_vs_unit_test(ProcessorsTest processorsTest.cpp) add_vs_lib_gpu_test(ProcessorsTest processorsTest.cpp)
add_vs_test_arg(ContourMatchingTest contourMatchingTest.cpp "cmd" "" ${OpenCV_LIBRARIES}) add_vs_test_arg(ContourMatchingTest contourMatchingTest.cpp "cmd gpu" "" ${OpenCV_LIBRARIES})
add_vs_test_arg(CoordTransformTest coordTransformTest.cpp "cmd" "") add_vs_test_arg(CoordTransformTest coordTransformTest.cpp "cmd gpu" "")
add_vs_test_arg(MaskInterpolationTest maskInterpolationTest.cpp "cmd" "") add_vs_test_arg(MaskInterpolationTest maskInterpolationTest.cpp "cmd gpu" "")
endif(${GPU_BACKEND_DEFAULT} STREQUAL CUDA) endif(${GPU_BACKEND_DEFAULT} STREQUAL CUDA)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment