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

4
list(REMOVE_ITEM TEST_OPS test_recognize_digits)
Y
Yang Yu 已提交
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
py_test(test_recognize_digits_mlp_cpu
  SRCS test_recognize_digits.py
  ARGS mlp)
py_test(test_recognize_digits_mlp_cuda
  SRCS test_recognize_digits.py
  ARGS mlp --use_cuda)
py_test(test_recognize_digits_conv_cpu
  SRCS test_recognize_digits.py
  ARGS conv)
py_test(test_recognize_digits_conv_cuda
  SRCS test_recognize_digits.py
  ARGS conv --use_cuda)
py_test(test_recognize_digits_mlp_cpu_parallel
  SRCS test_recognize_digits.py
  ARGS mlp --parallel)
py_test(test_recognize_digits_mlp_cuda_parallel
  SRCS test_recognize_digits.py
  ARGS mlp --use_cuda --parallel)
py_test(test_recognize_digits_conv_cpu_parallel
  SRCS test_recognize_digits.py
  ARGS conv --parallel)
py_test(test_recognize_digits_conv_cuda_parallel
  SRCS test_recognize_digits.py
  ARGS conv --use_cuda --parallel)
29 30

# default test
31 32 33
foreach(src ${TEST_OPS})
    py_test(${src} SRCS ${src}.py)
endforeach()