mirror of
https://github.com/Unidata/netcdf-c.git
synced 2025-02-17 16:50:18 +08:00
netcdf-c: Make cmake pass a windows cmd prompt
add_sh_test only creates the test if HAVE_BASH is TRUE. Therefore we can only call SET_TESTS_PROPERTIES on the created test if HAVE_BASH is equally true.
This commit is contained in:
parent
f06e98ba6d
commit
3af477a926
@ -7,9 +7,11 @@ FOREACH(F ${CDL_EXAMPLE_TESTS})
|
||||
add_sh_test(cdl ${F})
|
||||
ENDFOREACH()
|
||||
|
||||
SET_TESTS_PROPERTIES(cdl_do_comps PROPERTIES DEPENDS C_tests_simple_xy_wr)
|
||||
SET_TESTS_PROPERTIES(cdl_do_comps PROPERTIES DEPENDS C_tests_sfc_pres_temp_wr)
|
||||
SET_TESTS_PROPERTIES(cdl_do_comps PROPERTIES DEPENDS C_test_pres_temp_4D_wr)
|
||||
IF(HAVE_BASH)
|
||||
SET_TESTS_PROPERTIES(cdl_do_comps PROPERTIES DEPENDS C_tests_simple_xy_wr)
|
||||
SET_TESTS_PROPERTIES(cdl_do_comps PROPERTIES DEPENDS C_tests_sfc_pres_temp_wr)
|
||||
SET_TESTS_PROPERTIES(cdl_do_comps PROPERTIES DEPENDS C_test_pres_temp_4D_wr)
|
||||
ENDIF(HAVE_BASH)
|
||||
|
||||
SET(CLEANFILES simple_xy.nc sfc_pres_temp.nc pres_temp_4D.nc)
|
||||
SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${CLEANFILES}")
|
||||
|
@ -121,7 +121,9 @@ ENDIF(MSVC)
|
||||
ENDIF(USE_STRICT_NULL_BYTE_HEADER_PADDING)
|
||||
|
||||
add_sh_test(ncdump tst_nccopy3)
|
||||
SET_TESTS_PROPERTIES(ncdump_tst_nccopy3 PROPERTIES RUN_SERIAL TRUE)
|
||||
IF(HAVE_BASH)
|
||||
SET_TESTS_PROPERTIES(ncdump_tst_nccopy3 PROPERTIES RUN_SERIAL TRUE)
|
||||
ENDIF(HAVE_BASH)
|
||||
|
||||
add_sh_test(ncdump tst_nccopy3_subset)
|
||||
add_sh_test(ncdump tst_charfill)
|
||||
@ -189,9 +191,11 @@ ENDIF(MSVC)
|
||||
add_sh_test(ncdump_sh tst_fillbug)
|
||||
|
||||
add_sh_test(ncdump tst_netcdf4_4)
|
||||
IF(MSVC)
|
||||
SET_TESTS_PROPERTIES(ncdump_tst_netcdf4_4 PROPERTIES WILL_FAIL TRUE)
|
||||
ENDIF(MSVC)
|
||||
IF(HAVE_BASH)
|
||||
IF(MSVC)
|
||||
SET_TESTS_PROPERTIES(ncdump_tst_netcdf4_4 PROPERTIES WILL_FAIL TRUE)
|
||||
ENDIF(MSVC)
|
||||
ENDIF(HAVE_BASH)
|
||||
|
||||
###
|
||||
# Some test reordering was required to ensure these tests
|
||||
@ -207,7 +211,9 @@ ENDIF(MSVC)
|
||||
add_sh_test(ncdump_shell tst_h_scalar)
|
||||
|
||||
add_sh_test(ncdump tst_nccopy4)
|
||||
SET_TESTS_PROPERTIES(ncdump_tst_nccopy4 PROPERTIES RUN_SERIAL TRUE)
|
||||
IF(HAVE_BASH)
|
||||
SET_TESTS_PROPERTIES(ncdump_tst_nccopy4 PROPERTIES RUN_SERIAL TRUE)
|
||||
ENDIF(HAVE_BASH)
|
||||
|
||||
IF(USE_NETCDF4)
|
||||
add_sh_test(ncdump tst_ncgen4)
|
||||
|
@ -14,4 +14,6 @@ ADD_TEST(nctest ${EXECUTABLE_OUTPUT_PATH}/nctest)
|
||||
add_bin_test_no_prefix(tst_rename)
|
||||
add_sh_test(nctest compare_test_files)
|
||||
|
||||
SET_TESTS_PROPERTIES(nctest_compare_test_files PROPERTIES DEPENDS nctest)
|
||||
IF(HAVE_BASH)
|
||||
SET_TESTS_PROPERTIES(nctest_compare_test_files PROPERTIES DEPENDS nctest)
|
||||
ENDIF(HAVE_BASH)
|
||||
|
Loading…
Reference in New Issue
Block a user