summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--MANIFEST1
-rw-r--r--tools/h5dump/CMakeLists.txt7
-rw-r--r--tools/h5dump/testh5dump.sh.in3
-rw-r--r--tools/testfiles/textlink.ddl15
-rw-r--r--windows/tools/h5dump/testh5dump.bat3
5 files changed, 29 insertions, 0 deletions
diff --git a/MANIFEST b/MANIFEST
index 51e5c2f..d867b9b 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -1188,6 +1188,7 @@
./tools/testfiles/texceedsubstride.ddl
./tools/testfiles/textlink.h5
./tools/testfiles/textlink.h5.xml
+./tools/testfiles/textlink.ddl
./tools/testfiles/textlinkfar.ddl
./tools/testfiles/textlinkfar.h5
./tools/testfiles/textlinksrc.ddl
diff --git a/tools/h5dump/CMakeLists.txt b/tools/h5dump/CMakeLists.txt
index 7b2cfc2..ccc666d 100644
--- a/tools/h5dump/CMakeLists.txt
+++ b/tools/h5dump/CMakeLists.txt
@@ -83,6 +83,7 @@ IF (BUILD_TESTING)
texternal.ddl
textlinksrc.ddl
textlinkfar.ddl
+ textlink.ddl
tfamily.ddl
tfill.ddl
tfletcher32.ddl
@@ -243,6 +244,7 @@ IF (BUILD_TESTING)
textlinkfar.h5
textlinksrc.h5
textlinktar.h5
+ textlink.h5
tfamily00000.h5
tfamily00001.h5
tfamily00002.h5
@@ -653,6 +655,8 @@ IF (BUILD_TESTING)
textlinksrc.out.err
textlinkfar.out
textlinkfar.out.err
+ textlink.out
+ textlink.out.err
tfamily.out
tfamily.out.err
tfill.out
@@ -1089,6 +1093,9 @@ IF (BUILD_TESTING)
ADD_H5_TEST (textlinksrc 0 textlinksrc.h5)
ADD_H5_TEST (textlinkfar 0 textlinkfar.h5)
+ # test for dangling external links
+ ADD_H5_TEST (textlink 0 textlink.h5)
+
####### test for dataset packed bits ######
IF (HDF5_USE_H5DUMP_PACKED_BITS)
# Remove any output file left over from previous test run
diff --git a/tools/h5dump/testh5dump.sh.in b/tools/h5dump/testh5dump.sh.in
index 1310b2c..d845fae 100644
--- a/tools/h5dump/testh5dump.sh.in
+++ b/tools/h5dump/testh5dump.sh.in
@@ -582,6 +582,9 @@ TOOLTEST tfpformat.ddl -m %.7f tfpformat.h5
TOOLTEST textlinksrc.ddl textlinksrc.h5
TOOLTEST textlinkfar.ddl textlinkfar.h5
+# test for dangling external links
+TOOLTEST textlink.ddl textlink.h5
+
# test for dataset packed bits
# Set up xCMD to test or skip.
if test "$Have_Packed_Bits" = "yes"; then
diff --git a/tools/testfiles/textlink.ddl b/tools/testfiles/textlink.ddl
new file mode 100644
index 0000000..0a43c47
--- /dev/null
+++ b/tools/testfiles/textlink.ddl
@@ -0,0 +1,15 @@
+#############################
+Expected output for 'h5dump textlink.h5'
+#############################
+HDF5 "textlink.h5" {
+GROUP "/" {
+ EXTERNAL_LINK "extlink1" {
+ TARGETFILE "filename"
+ TARGETPATH "objname"
+ }
+ EXTERNAL_LINK "extlink2" {
+ TARGETFILE "anotherfile"
+ TARGETPATH "anotherobj"
+ }
+}
+}
diff --git a/windows/tools/h5dump/testh5dump.bat b/windows/tools/h5dump/testh5dump.bat
index 757c6cc..aad7d6c 100644
--- a/windows/tools/h5dump/testh5dump.bat
+++ b/windows/tools/h5dump/testh5dump.bat
@@ -624,6 +624,9 @@ rem ############################################################################
rem tests for traversal of external links
call :tooltest textlinksrc.ddl textlinksrc.h5
call :tooltest textlinkfar.ddl textlinkfar.h5
+
+ rem test for dangling external links
+ call :tooltest textlink.ddl textlink.h5
rem tests for traversal of external links
call :tooltest textlinksrc.ddl textlinksrc.h5