CMakeLists.txt 1.0 KB
Newer Older
Z
zhangjinchao01 已提交
1 2 3 4
# unittest for common package

add_simple_unittest(test_ExecViaCpu)
add_simple_unittest(test_SIMDFunctions)
H
hedaoyuan 已提交
5
add_simple_unittest(test_TrainingAlgorithm)
6
add_simple_unittest(test_SparseMatrix)
Z
zhangjinchao01 已提交
7 8 9

# TODO(yuyang18): Refactor TestUtil.cpp. Remove this cross module reference.
add_unittest(test_matrixCompare
10
    test_matrixCompare.cpp)
Z
zhangjinchao01 已提交
11 12 13 14 15

add_simple_unittest(test_sparseMatrixCompare)
add_simple_unittest(test_perturbation)
add_simple_unittest(test_CpuGpuVector)
add_simple_unittest(test_Allocator)
16

H
hedaoyuan 已提交
17
if(WITH_GPU)
H
hedaoyuan 已提交
18 19 20 21
    CUDA_ADD_EXECUTABLE(test_Tensor test_Tensor.cu)
    link_paddle_test(test_Tensor)
    CUDA_ADD_EXECUTABLE(test_lazyAssign test_lazyAssign.cu)
    link_paddle_test(test_lazyAssign)
H
hedaoyuan 已提交
22 23 24
else()
    compile_cu_as_cpp(test_Tensor.cu)
    add_unittest(test_Tensor test_Tensor.cu)
H
hedaoyuan 已提交
25 26
    compile_cu_as_cpp(test_lazyAssign.cu)
    add_unittest(test_lazyAssign test_lazyAssign.cu)
H
hedaoyuan 已提交
27 28
endif(WITH_GPU)

29
add_simple_unittest(test_FPException)
30
add_simple_unittest(test_GpuProfiler)
31 32
add_simple_unittest(test_BaseMatrix)
add_simple_unittest(test_Matrix)