summaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authorAllen Byrne <50328838+byrnHDF@users.noreply.github.com>2021-11-03 22:33:00 (GMT)
committerGitHub <noreply@github.com>2021-11-03 22:33:00 (GMT)
commitd952c863b2869887af8d9b987d2e80f41a6231a7 (patch)
tree9737b5bdae5615657f4f27a6c073bb3ef12aadbf /java
parentd8871dbf2756c1c1804b7611c805e3e21ac251d7 (diff)
downloadhdf5-d952c863b2869887af8d9b987d2e80f41a6231a7.zip
hdf5-d952c863b2869887af8d9b987d2e80f41a6231a7.tar.gz
hdf5-d952c863b2869887af8d9b987d2e80f41a6231a7.tar.bz2
Merge Fix Java VOL tests #1158 (#1160)
Diffstat (limited to 'java')
-rw-r--r--java/test/CMakeLists.txt22
1 files changed, 9 insertions, 13 deletions
diff --git a/java/test/CMakeLists.txt b/java/test/CMakeLists.txt
index 7aed8f1..70067fc 100644
--- a/java/test/CMakeLists.txt
+++ b/java/test/CMakeLists.txt
@@ -113,14 +113,14 @@ endif ()
get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME)
set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>;")
+set (CMAKE_JAVA_CLASSPATH ".")
+foreach (CMAKE_INCLUDE_PATH ${CMAKE_JAVA_INCLUDE_PATH})
+ set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${CMAKE_INCLUDE_PATH}")
+endforeach ()
if (HDF5_TEST_JAVA AND HDF5_TEST_SERIAL)
foreach (test_file ${HDF5_JAVA_TEST_SOURCES})
- set (CMAKE_JAVA_CLASSPATH ".")
- foreach (CMAKE_INCLUDE_PATH ${CMAKE_JAVA_INCLUDE_PATH})
- set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${CMAKE_INCLUDE_PATH}")
- endforeach ()
- set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${${HDF5_JAVA_TEST_LIB_TARGET}_${test_file}_JAR_FILE}")
+ set (TEST_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${${HDF5_JAVA_TEST_LIB_TARGET}_${test_file}_JAR_FILE}")
add_test (
NAME JUnit-${test_file}-clearall-objects
@@ -132,7 +132,7 @@ if (HDF5_TEST_JAVA AND HDF5_TEST_SERIAL)
NAME JUnit-${test_file}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_TESTER=${CMAKE_Java_RUNTIME};${CMAKE_Java_RUNTIME_FLAGS}"
- -D "TEST_CLASSPATH:STRING=${CMAKE_JAVA_CLASSPATH}"
+ -D "TEST_CLASSPATH:STRING=${TEST_JAVA_CLASSPATH}"
-D "TEST_ARGS:STRING=${CMD_ARGS}-ea;org.junit.runner.JUnitCore"
-D "TEST_PROGRAM=test.${test_file}"
-D "TEST_LIBRARY_DIRECTORY=${CMAKE_TEST_OUTPUT_DIRECTORY}"
@@ -184,7 +184,7 @@ if (HDF5_TEST_JAVA AND HDF5_TEST_SERIAL)
-D "TEST_MASK_ERROR=TRUE"
# -D "TEST_FILTER:STRING=${testfilter}"
-D "TEST_REFERENCE=JUnit-${volname}-${voltest}.txt"
- -P "${HDF_RESOURCES_DIR}/jvolTest.cmake"
+ -P "${HDF_RESOURCES_DIR}/jrunTest.cmake"
)
set_tests_properties (JUnit-VOL-${volname}-${voltest} PROPERTIES
ENVIRONMENT "HDF5_PLUGIN_PATH=${CMAKE_BINARY_DIR}/testdir2"
@@ -226,12 +226,8 @@ if (HDF5_TEST_JAVA AND HDF5_TEST_SERIAL)
foreach (volinfo IN LISTS ${voltest})
foreach (h5_file ${HDF5_JAVA_TEST_SOURCES})
- set (CMAKE_JAVA_CLASSPATH ".")
- foreach (CMAKE_INCLUDE_PATH ${CMAKE_JAVA_INCLUDE_PATH})
- set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${CMAKE_INCLUDE_PATH}")
- endforeach ()
- set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${${HDF5_JAVA_TEST_LIB_TARGET}_${h5_file}_JAR_FILE}")
- DO_VOL_TEST (${h5_file} ${voltest} "${volinfo}" ${CMAKE_JAVA_CLASSPATH})
+ set (VOL_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${${HDF5_JAVA_TEST_LIB_TARGET}_${h5_file}_JAR_FILE}")
+ DO_VOL_TEST (${h5_file} ${voltest} "${volinfo}" "${VOL_JAVA_CLASSPATH}")
endforeach ()
endforeach ()
endforeach ()