From 48514c008f8b4a79369aeafc68c0e2a3a1dc6cbd Mon Sep 17 00:00:00 2001 From: Quincey Koziol Date: Thu, 8 Dec 2005 14:35:34 -0500 Subject: [svn-r11774] Purpose: Extra test Description: Add test to make certain that trying to call H5Fopen() on a non-existant file fails. Platforms tested: FreeBSD 4.11 (sleipnir) Too minor to require h5committest --- test/tfile.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/test/tfile.c b/test/tfile.c index 84c96ca..83951ff 100644 --- a/test/tfile.c +++ b/test/tfile.c @@ -105,12 +105,17 @@ test_file_create(void) /* Output message about test being performed */ MESSAGE(5, ("Testing Low-Level File Creation I/O\n")); + /* First ensure the file does not exist */ + remove(FILE1); + + /* Try opening a non-existant file */ + fid1 = H5Fopen(FILE1, H5F_ACC_RDWR, H5P_DEFAULT); + VERIFY(fid1, FAIL, "H5Fopen"); + /* Test create with various sequences of H5F_ACC_EXCL and */ /* H5F_ACC_TRUNC flags */ /* Create with H5F_ACC_EXCL */ - /* First ensure the file does not exist */ - remove(FILE1); fid1 = H5Fcreate(FILE1, H5F_ACC_EXCL, H5P_DEFAULT, H5P_DEFAULT); CHECK(fid1, FAIL, "H5Fcreate"); -- cgit v0.12