CMakeLists.txt 521 字节
Newer Older
1 2 3 4
file(GLOB TEST_OPS RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "test_*.py")
string(REPLACE ".py" "" TEST_OPS "${TEST_OPS}")

# default test
J
JiabinYang 已提交
5 6 7 8 9 10 11 12 13 14 15 16 17
if(NOT APPLE)
    foreach(src ${TEST_OPS})
        py_test(${src} SRCS ${src}.py)
    endforeach()
else()
    foreach(src ${TEST_OPS})
        if(${src} STREQUAL "test_recognize_digits_conv")
            message(WARNING "These tests has been disabled in OSX for random fail: \n" ${src})
        else()
            py_test(${src} SRCS ${src}.py)
        endif()
    endforeach()
endif()