summaryrefslogtreecommitdiffstats
path: root/java/test/TestH5Pfapl.java
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2016-11-30 23:12:35 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2016-11-30 23:12:35 (GMT)
commit65be68a17d1e5bec7e51e5f3e2e03d22163f7817 (patch)
tree4fbed27e66a41c3d8cb6f4f75f30ffe923f9185c /java/test/TestH5Pfapl.java
parent5922bbb45f03b0e84c3aef7e1ed1010273caa7e2 (diff)
downloadhdf5-65be68a17d1e5bec7e51e5f3e2e03d22163f7817.zip
hdf5-65be68a17d1e5bec7e51e5f3e2e03d22163f7817.tar.gz
hdf5-65be68a17d1e5bec7e51e5f3e2e03d22163f7817.tar.bz2
Add some Java methods that were missed earlier.
Diffstat (limited to 'java/test/TestH5Pfapl.java')
-rw-r--r--java/test/TestH5Pfapl.java55
1 files changed, 55 insertions, 0 deletions
diff --git a/java/test/TestH5Pfapl.java b/java/test/TestH5Pfapl.java
index 555afe0..8f15648 100644
--- a/java/test/TestH5Pfapl.java
+++ b/java/test/TestH5Pfapl.java
@@ -1322,4 +1322,59 @@ public class TestH5Pfapl {
}
}
}
+
+ @Test
+ public void testH5Fmdc_logging() {
+ boolean[] mdc_logging_status = {false, false};
+ boolean[] mdc_log_options = {false, false};
+
+ try {
+ boolean is_enabled = true;
+ boolean start_on_access = false;
+ H5.H5Pset_mdc_log_options(fapl_id, is_enabled, H5_LOG_FILE, start_on_access);
+
+ String location = H5.H5Pget_mdc_log_options(fapl_id, mdc_log_options);
+ assertTrue("H5.H5Pget_mdc_log_options: is_enabled", mdc_log_options[0]);
+ assertFalse("H5.H5Pget_mdc_log_options: start_on_access_out", mdc_log_options[1]);
+
+ H5.H5Pset_libver_bounds(fapl_id, HDF5Constants.H5F_LIBVER_LATEST, HDF5Constants.H5F_LIBVER_LATEST);
+ }
+ catch (Throwable err) {
+ err.printStackTrace();
+ fail("mdc_log_option: " + err);
+ }
+ _createH5File(fapl_id);
+
+ try {
+ H5.H5Fget_mdc_logging_status(H5fid, mdc_logging_status);
+ }
+ catch (Throwable err) {
+ fail("H5.H5Fget_mdc_logging_status: " + err);
+ }
+ assertTrue("initial: is_enabled", mdc_logging_status[0]);
+ assertFalse("initial: is_currently_logging", mdc_logging_status[1]);
+
+ try {
+ H5.H5Fstart_mdc_logging(H5fid);
+ H5.H5Fget_mdc_logging_status(H5fid, mdc_logging_status);
+ }
+ catch (Throwable err) {
+ fail("start H5.H5Fget_mdc_logging_status: " + err);
+ }
+ assertTrue("start: is_enabled", mdc_logging_status[0]);
+ assertTrue("start: is_currently_logging", mdc_logging_status[1]);
+
+ try {
+ H5.H5Fstop_mdc_logging(H5fid);
+ H5.H5Fget_mdc_logging_status(H5fid, mdc_logging_status);
+ }
+ catch (Throwable err) {
+ fail("stop H5.H5Fget_mdc_logging_status: " + err);
+ }
+// assertFalse("stop: is_enabled", mdc_logging_status[0]);
+ assertFalse("stop: is_currently_logging", mdc_logging_status[1]);
+
+ deleteH5file();
+ _deleteLogFile();
+ }
}