COIN-OR::LEMON - Graph Library

Changeset 1107:2b6bffe0e7e8 in lemon for test/CMakeLists.txt


Ignore:
Timestamp:
12/20/11 18:15:14 (9 years ago)
Author:
Alpar Juttner <alpar@…>
Branch:
default
Parents:
1106:7c4ba7daaf5f (diff), 1057:633956ca9421 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Phase:
public
Message:

Merge

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • test/CMakeLists.txt

    r953 r1107  
    77  ${PROJECT_BINARY_DIR}/lemon
    88)
     9
     10SET(TEST_WITH_VALGRIND "NO" CACHE STRING
     11  "Run the test with valgrind (YES/NO).")
     12SET(VALGRIND_FLAGS "" CACHE STRING "Valgrind flags used by the tests.")
    913
    1014SET(TESTS
     
    3034  heap_test
    3135  kruskal_test
     36  lgf_test
    3237  maps_test
    3338  matching_test
     
    4651
    4752IF(LEMON_HAVE_LP)
    48   ADD_EXECUTABLE(lp_test lp_test.cc)
     53  IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
     54    ADD_EXECUTABLE(lp_test lp_test.cc)
     55  ELSE()
     56    ADD_EXECUTABLE(lp_test EXCLUDE_FROM_ALL lp_test.cc)
     57  ENDIF()
     58
    4959  SET(LP_TEST_LIBS lemon)
    5060
     
    6171  TARGET_LINK_LIBRARIES(lp_test ${LP_TEST_LIBS})
    6272  ADD_TEST(lp_test lp_test)
     73  ADD_DEPENDENCIES(check lp_test)
    6374
    6475  IF(WIN32 AND LEMON_HAVE_GLPK)
     
    8293
    8394IF(LEMON_HAVE_MIP)
    84   ADD_EXECUTABLE(mip_test mip_test.cc)
     95  IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
     96    ADD_EXECUTABLE(mip_test mip_test.cc)
     97  ELSE()
     98    ADD_EXECUTABLE(mip_test EXCLUDE_FROM_ALL mip_test.cc)
     99  ENDIF()
     100
    85101  SET(MIP_TEST_LIBS lemon)
    86102
     
    97113  TARGET_LINK_LIBRARIES(mip_test ${MIP_TEST_LIBS})
    98114  ADD_TEST(mip_test mip_test)
     115  ADD_DEPENDENCIES(check mip_test)
    99116
    100117  IF(WIN32 AND LEMON_HAVE_GLPK)
     
    118135
    119136FOREACH(TEST_NAME ${TESTS})
    120   ADD_EXECUTABLE(${TEST_NAME} ${TEST_NAME}.cc)
     137  IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
     138    ADD_EXECUTABLE(${TEST_NAME} ${TEST_NAME}.cc)
     139  ELSE()
     140    ADD_EXECUTABLE(${TEST_NAME} EXCLUDE_FROM_ALL ${TEST_NAME}.cc)
     141  ENDIF()
    121142  TARGET_LINK_LIBRARIES(${TEST_NAME} lemon)
    122   ADD_TEST(${TEST_NAME} ${TEST_NAME})
     143    IF(TEST_WITH_VALGRIND)
     144      ADD_TEST(${TEST_NAME}
     145        valgrind --error-exitcode=1 ${VALGRIND_FLAGS}
     146        ${CMAKE_CURRENT_BINARY_DIR}/${TEST_NAME} )
     147    ELSE()
     148      ADD_TEST(${TEST_NAME} ${TEST_NAME})
     149    ENDIF()
     150  ADD_DEPENDENCIES(check ${TEST_NAME})
    123151ENDFOREACH()
  • test/CMakeLists.txt

    r1069 r1107  
    1414SET(TESTS
    1515  adaptors_test
     16  bellman_ford_test
    1617  bfs_test
    1718  circulation_test
     
    2526  error_test
    2627  euler_test
     28  fractional_matching_test
    2729  gomory_hu_test
    2830  graph_copy_test
     
    3739  min_cost_arborescence_test
    3840  min_cost_flow_test
     41  min_mean_cycle_test
    3942  path_test
     43  planarity_test
    4044  preflow_test
    4145  radix_sort_test
Note: See TracChangeset for help on using the changeset viewer.