Commit Graph

49 Commits

Author SHA1 Message Date
Binh-Minh Ribler
0befe65753 [svn-r25632] Purpose: Fixed HDFFV-8852
Description:
    H5F_ACC_CREAT was included in the C++ API while the C library doesn't
    allow it yet.  Possibly, in the future, but not now.  In addition, the
    two flags H5F_ACC_RDONLY and H5F_ACC_RDWR were missing from the
    documentation, causing confusion that appending is not supported.
Solution:
    - Removed H5F_ACC_CREAT from the function until the C library support it
    - Added H5F_ACC_RDONLY and H5F_ACC_RDWR to the comments to update the
      documentation
Platforms tested:
    Linux/ppc64 (ostrich)
    Linux/32 2.6 (jam)
    SunOS 5.11 (emu)
2014-09-29 15:52:08 -05:00
Binh-Minh Ribler
0dc4ce3704 [svn-r24994] Purpose: Removed some warnings
Description:
    Turned on warnings and removed some of those.
Platforms tested:
    Linux/ppc64 (ostrich)
    Linux/32 2.6 (jam)
    SunOS 5.11 (emu)
2014-04-08 23:03:03 -05:00
Binh-Minh Ribler
a08f75b073 [svn-r24969] Description:
- Added wrappers to H5Object for H5Iget_name() to get object's name
        ssize_t getObjName(char *obj_name, size_t buf_size = 0) const;
        ssize_t getObjName(H5std_string& obj_name, size_t len = 0) const;
        H5std_string getObjName() const;
    - Added tests tobject.cpp
    - Added to various cleanup_* functions in tests to remove generated files
    - Added an overload H5I_type_t getHDFObjType() to get object's type
Platforms tested:
    Linux/ppc64 (ostrich)
    Linux/32 2.6 (jam)
    SunOS 5.11 (emu) with gmake
2014-04-06 17:36:15 -05:00
Binh-Minh Ribler
67be45610f [svn-r24867] Description:
- Added a null terminator to the comment returned from the C call, in
        getComment methods
    - Some minor cleanup
Platforms tested:
    Linux/ppc64 (ostrich)
    Linux/32 2.6 (jam)
    Linux/64 2.6 (platypus)/PGI compilers
2014-03-22 15:39:44 -05:00
Binh-Minh Ribler
60df159d33 [svn-r24865] Description:
- Added another overload for char* argument:
        ssize_t getComment(const char* name, const size_t buf_size, char* comment)
    - Changed default value to 0 for the other two getComment methods
    - Added HDmemset to after every char string allocation to clear the buffer
Platforms tested:
    Linux/ppc64 (ostrich)
    Linux/32 2.6 (jam)
    Linux/64 2.6 (platypus)/PGI compilers
2014-03-21 18:23:05 -05:00
Binh-Minh Ribler
f8fb310610 [svn-r24188] Purpose: Fixed bug introduced in r24163
Description:
    - The failure in daily test was caused by missing initialization of member
    "id" in a few constructors.  This is now fixed.
    - Added two overloaded H5Location::setComment
    - Improved some error reporting in H5Location
    - Improved error reporting in tests
Platforms tested:
    Linux/32 2.6 (jam)
    SunOS 5.11 (emu)
    Linux/64 2.6 (koala)/PGI compilers
2013-09-22 19:39:44 -05:00
Binh-Minh Ribler
27ed849cad [svn-r24142] Purpose: Fix bug in tests
Description:
    - Passing the c_str() of an std string into a C function caused failure
      on OpenVMS.  Added a work around using temporary string. (th5s.cpp)
    - Passing incorrect file access property list caused test_datasize() to
      fail.  Fixed.
    - Close a group in test_dset, before the file can be properly closed.
      This should fix the problem on OpenVMS.
Platforms tested:
    Linux/32 2.6 (jam)
    SunOS 5.11 (emu)
    Linux/ppc64 (ostrich)
2013-09-14 22:53:59 -05:00
Binh-Minh Ribler
c8018386da [svn-r23427] Purpose: Fix bug HDFFV-8067
Description:
  + The C++ test failed with the new PGI compilers versions 12.4 and 12.5
  + An exception thrown by an internal function, which was called by
    a constructor, was not propagating to the test program during the stack
    unwinding, so it couldn't be caught by the test and the program terminated.
  + Various trials and errors indicated that the problem is where an STD string
    converted to a char* being passed to the internal function, but confirmation
    has not been found yet.  It could be a compiler bug.
Solution:
  + Added a try/catch in the constructor around the internal function and
    re-throw the exception when it is caught.  This is a workaround.
  + Unrelated minor fixes: removed unused variables and MESSAGE's; commented
    out tvlstr.cpp/test_read_vl_string_attribute because it may be redundant,
    and commented out H5Tpkg.h inclusion because TEST_ALIGNMENT is not added
    yet and probably not necessary in the C++ API.
Platforms tested:
    Linux/32 2.6 (jam) with PGI compilers
    Linux/32 2.6 (jam) with GNU compilers
    Linux/64 2.6 (koala)
2013-03-22 12:56:05 -05:00
Binh-Minh Ribler
9c3f82fbd7 [svn-r22845] Purpose: Misc fixes
Description:
    Fixed miscellaneous inconsistencies and typos, which also took
    care of the failure in Packet Table test on daily test today.
Platforms tested:
    Linux/32 2.6 (jam)
    Linux/64 2.6 (koala)
    Mac Lion (duck)
2012-09-28 17:18:33 -05:00
Binh-Minh Ribler
19a6303205 [svn-r22128] Purpose: Fixed bug 4279
Description:
    Closed various HDF5 objects in DataSet::getInMemDataSize and
    Attribute::getInMemDataSize to remove some memory leaks.
Platforms tested:
    Linux/32 2.6 (jam)
    Linux/64 2.6 (amani)
    SunOS 5.10 (linew)
2012-03-22 19:50:36 -05:00
Binh-Minh Ribler
1de0aa8b9b [svn-r18349] Description:
In the previous revision, dsets.cpp was moved from a standalone
    program into testhdf5.cpp to be consistent with the rest of the
    tests.  Makefiles were left out by mistake.
Platform tested:
    Verified on Linux/32 2.6 (jam)
2010-02-27 23:09:19 -05:00
Binh-Minh Ribler
c90711e713 [svn-r18335] Description:
Removed header file testhdf5.h from C++ tests to eliminate a non-standard
    problem on OpenVMS.  It wasn't essential.

Platforms tested:
    Linux/32 2.6 (jam)
    FreeBSD/64 6.3 (liberty)
    Ray agreed to test on OpenVMS.
2010-02-26 11:55:49 -05:00
Neil Fortner
8c074d5c03 [svn-r16807] Purpose: Fix bug 1533
Description:
Previously, there was no versioning for H5Z_class_t.  This prevented applications
written for 1.6 using custom filters from being able to use the 1.8 library.
There is now an H5Z_class1_t and H5Z_class2_t to enable compatibility.  H5Zregister is
*not* versioned, it determines which version of the struct has been passed in by the
value of the first field (id or version, both are ints).

Tested: jam, linew, smirom (h5committest), jam (--with-default-api-version=v16)
2009-04-20 14:12:19 -05:00
Quincey Koziol
9f60f016ab [svn-r15800] Description:
Bring file free space branch changes through r15795 into trunk, which
includes a fair bit of code cleanup & rearrangement along with a couple of
bug fixes also.

Tested on:
        Mac OS X/32 10.5.5 (amazon) in debug mode
        Mac OS X/32 10.5.5 (amazon) w/C++ & FORTRAN, w/threadsafe,
                                in production mode
        FreeBSD/32 6.3 (duty) in debug mode
        FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode
        Linux/32 2.6 (kagiso) w/PGI compilers, w/C++ & FORTRAN, w/threadsafe,
                                in debug mode
        Linux/64-amd64 2.6 (smirom) w/Intel compilers w/default API=1.6.x,
                                w/C++ & FORTRAN, in production mode
        Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
                                w/szip filter, in production mode
        Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN,
                                in production mode
        Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in production mode
        Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode
2008-10-06 23:17:35 -05:00
Quincey Koziol
507a211257 [svn-r15462] Description:
Correct compiler warnings from Visual Studio.

Tested on:
    Mac OS X/32 10.5.4 (amazon) w/FORTRAN & C++
    (Too minor to require full h5committest)
2008-08-12 07:46:40 -05:00
Binh-Minh Ribler
1c4e6d163f [svn-r13524] Purpose: Cleanup tests
Description:
	Added extern "C" to cleanup functions as well, forgot last time.
	Cleaned up/Added comments to some of the newly added tests.

Platforms tested
    AIX 5.1 (copper)
    Linux 2.6 (kagiso)
    SunOS 5.8 64-bit (sol)
2007-03-17 11:26:53 -05:00
Albert Cheng
ed7d456e51 [svn-r13253] Updated all C and C++ style source code files with the THG copyright notice.
Tested platform:
Kagiso only since it is only a comment block change.  If it works in one
machine, it should work in all, I hope.  Still need to check the parallel
build on copper.
2007-02-07 09:56:24 -05:00
Binh-Minh Ribler
38480e6657 [svn-r13210] Purpose: Adding test
Description:
    - Added a brief test for DSetCreatPropList::setSzip.  More through tests
      will be added later.
    - Moved check_values from dsets.cpp into h5cpputil.cpp for sharing
      with other tests.

Platforms tested
    AIX 5.1 (copper)
    SunOS 5.8 64-bit (sol)
    Linux 2.6 (kagiso)
2007-01-28 21:41:27 -05:00
Binh-Minh Ribler
8b90adeac6 [svn-r12296] Purpose: Maintenance
Description:
    dsets.cpp: added a missing PASSED call to line up output better.
    tattr.cpp: casted parameters to verify_val properly to fix compilation
                errors on Windows, introduced from the previous checkin.

Platforms tested:
    Linux 2.4 (heping) - very minor
    Windows XP
2006-04-25 13:02:28 -05:00
Elena Pourmal
11cf4bacb7 [svn-r12252] Purpose: Maintenance
Description: Brought VMS changes back (very minor):
             In tfile.cpp file some tests for open and creation should fail on UNIX,
             but this is not true on VMS since it has versioning of the files.
             In dsets.cpp std::count was used, but it is not available on VMS; also
             VMS didn't like "bogus" name for the filter function.


Solution: Used H5_HAVE_FILE_VERSIONS and H5_VMS variables to control the tests;
          replaced "bogus" function with "filter_bogus" function

Platforms tested: VMS server, heping

Misc. update:
2006-04-14 16:39:46 -05:00
Binh-Minh Ribler
e36db373ef [svn-r12202] Purpose: Maintenance
Description:
    Changed to alias string instead of std, i.e. H5std_string instead
    of H5std, because the old way wasn't working when std didn't exist.

Platforms tested:
    Linux 2.4 (heping)
    SunOS 5.8 64-bit (sol)
    HPUX 11.00 (kelgia) - this was the problematic platform but I wasn't
                                able to test before.
2006-04-05 11:50:56 -05:00
Binh-Minh Ribler
a7e993d72b [svn-r12180] Purpose: Maintenance
Description:
    Added alias H5_std so either the global or std namespace can be
    used, depending on H5_NO_STD.

Platforms tested:
    Linux 2.4 (heping)
    SunOS 5.8 64-bit (sol)
    AIX 5.1 (copper)
2006-03-30 13:06:58 -05:00
Binh-Minh Ribler
3e013d1930 [svn-r11883] Purpose: Fixed bug
Description:
    Removed the call to h5_test from dsets.cpp, since resetting
        the library made the C++ global constants become invalid.

Platforms tested:
    Linux 2.4 (heping)
    SunOS 5.8 64-bit (sol)
2006-01-17 20:37:52 -05:00
Binh-Minh Ribler
2b41179280 [svn-r11756] Purpose: Test improvement
Description:
    Improved the use of std members.

Platforms tested:
    Linux 2.4 (heping)
    SunOS 5.8 64-bit (sol)
    Linux 2.4 w/PGI (colonelk)
2005-12-03 07:27:14 -05:00
Quincey Koziol
6e7ed46998 [svn-r11487] Purpose:
Code cleanup

Description:
    Tweak copyright on C++ source files to reduce whining by copyright checking
script.

Platforms tested:
    FreeBSD 4.11 (sleipnir) w/C++
2005-10-01 10:29:18 -05:00
Quincey Koziol
6b45f5172c [svn-r11245] Purpose:
Code cleanup

Description:
    Trim trailing whitespace, which is making 'diff'ing the two branches
difficult.

Solution:
    Ran this script in each directory:

foreach f (*.[ch] *.cpp)
    sed 's/[[:blank:]]*$//' $f > sed.out && mv sed.out $f
end


Platforms tested:
    FreeBSD 4.11 (sleipnir)
    Too minor to require h5committest
2005-08-13 15:53:35 -05:00
Binh-Minh Ribler
828c6646a1 [svn-r10953] Purpose: Updating C++ tests
Description:
    Updated various comments/headers.

Platforms tested:
    Linux 2.4 (heping)
    AIX 5.1 (copper)
2005-06-19 16:02:21 -05:00
Binh-Minh Ribler
99d26d20f8 [svn-r10242] Purpose: Updating C++ tests
Description:
    Added an overloaded function for the template function verify_val.
    Updated various comments/headers.

Platforms tested:
    Linux 2.4 (heping)
    AIX 5.1 (copper)
2005-03-19 23:01:25 -05:00
Binh-Minh Ribler
dfd0b59ae6 [svn-r9829] Purpose: Clean up tests
Description:
    + replaced "goto error" with throw exceptions
    + properly cleanup dynamically allocated memory in failure cases,
        for in some cases, the execution continues on after the failures
        were reported.
    + added test utility class InvalidActionException for when an action
        should cause an exception but doesn't.

Platforms tested:
    SunOS 5.7 (arabica)
    Linux 2.4 (eirene)

    Note that there was an error due to the missing symbol H5E_LEN.  To
    be able to test my changes, I temporarily replaced H5E_LEN in c++/src
    with a constant as in the C tests, before the problem can be fixed.
    This value doesn't effect the C++ tests at all, at this time.
2005-01-16 10:23:34 -05:00
Quincey Koziol
427ff7da28 [svn-r9727] Purpose:
Bug Fix/Code Cleanup/Doc Cleanup/Optimization/Branch Sync :-)

Description:
    Generally speaking, this is the "signed->unsigned" change to selections.
However, in the process of merging code back, things got stickier and stickier
until I ended up doing a big "sync the two branches up" operation.  So... I
brought back all the "infrastructure" fixes from the development branch to the
release branch (which I think were actually making some improvement in
performance) as well as fixed several bugs which had been fixed in one branch,
but not the other.

    I've also tagged the repository before making this checkin with the label
"before_signed_unsigned_changes".

Platforms tested:
    FreeBSD 4.10 (sleipnir) w/parallel & fphdf5
    FreeBSD 4.10 (sleipnir) w/threadsafe
    FreeBSD 4.10 (sleipnir) w/backward compatibility
    Solaris 2.7 (arabica) w/"purify options"
    Solaris 2.8 (sol) w/FORTRAN & C++
    AIX 5.x (copper) w/parallel & FORTRAN
    IRIX64 6.5 (modi4) w/FORTRAN
    Linux 2.4 (heping) w/FORTRAN & C++


Misc. update:
2004-12-29 09:26:20 -05:00
Binh-Minh Ribler
d091bda690 [svn-r9698] Purpose: Correct typo
Description:
    Accidentally edited this file and removed a couple characters from a
    defined name, thus caused undefined error in daily test.  Fixed!

Platforms tested:
    SunOS 5.7 (arabica)
2004-12-21 09:28:59 -05:00
Binh-Minh Ribler
625e6ad9aa [svn-r9696] Purpose: Clean up tests
Description:
    Replaced cout's with cerr's.
    Replaced macro VERIFY with template function verify_val to
        verify read data/info.
    Cleanup various places in the tests to make them more consistent.

Platforms tested:
    SunOS 5.7 (arabica)
    Linux 2.4 (eirene)
2004-12-20 15:01:46 -05:00
James Laird
eab58732d8 [svn-r8781]
Purpose:
HDF5 now supports SZIP with no encoder.

Description:
SZIP can be configured to have both encoder and decoder or just to have the decoder.  HDF5 can now query the configuration of any filter, and will throw errors if users try to write using a filter with encoding disabled.

Solution:
Added H5Zget_filter_info function, changed API for H5Pget_filter and H5P_get_filter_by_id.  See SZIP RFC.

Platforms tested:
Copper (fortran, C++, parallel), Sleipnir (C++), Arabica (fortran, C++), Verbena (fortran, C++)

Misc. update:
2004-07-01 12:38:04 -05:00
Quincey Koziol
4e23c80758 [svn-r7181] Purpose:
Version update

Description:
    Removed 1.4 compatibility code in the library.

Platforms tested:
    FreeBSD 4.8 (sleipnir)
    h5committest
2003-07-07 14:02:46 -05:00
Binh-Minh Ribler
ee38b91d18 [svn-r7012] Purpose:
Text cleanup

Description:
    Re-worded some informative and error messages.
    Remove/Updated outdated comments.

Platforms:
    Linux 2.4 (eirene)
    IRIX 6.5.11 (modi4)
2003-06-09 23:03:58 -05:00
Binh-Minh Ribler
01f726e305 [svn-r6997]
Purpose:
    Code cleanup

Description:
    Moved a utility function out so other tests can use the same
    function and avoid code duplication.  Future utility functions
    can also benefit from this move.

Platforms tested:
    SunOS 5.7 (arabica)
    Linux 2.4 (eirene)
    IRIX 6.5.11 (modi4)
    HPUX 11.00 (kelgia)
2003-06-09 12:42:02 -05:00
Raymond Lu
b58192dfe7 [svn-r6779] Purpose: Backward compatibility change
Description: 1.4 compatibility for H5G_obj_t type and H5Zregister test.

Solution: use macro H5_WANT_H5_V1_4_COMPAT

Platforms tested: h5committest
2003-04-29 14:49:48 -05:00
Quincey Koziol
33bad44a26 [svn-r6616] Purpose:
Code cleanup

Description:
    Chase H5Zfilter API changes.

Solution:

Platforms tested:
    FreeBSD 4.8 (sleipnir) w/C++

Misc. update:
2003-04-09 09:27:01 -05:00
Bill Wendling
e12c035350 [svn-r6484] Purpose:
Bug Fix
Description:
    Kelgia needs the old header file format for #includes.
Solution:
    Conditionally include the old header file format if
    OLD_HEADER_FILENAME is defined.
Platforms tested:
    Kelgia
2003-03-17 11:41:02 -05:00
Binh-Minh Ribler
7fd449cb79 [svn-r6236] Purpose: Copyright
Description:
    Added copyright notice to C++ API files, including *.h, *.cpp, and
    Makefile.in

Platforms:
    Linux 6.2 (eirene)
2003-01-06 23:22:12 -05:00
Quincey Koziol
be76b331a1 [svn-r6111] Purpose:
Code cleanup/new feature

Description:
    Switched from using H5_HAVE_COMPRESSION flag in favor of
    H5_HAVE_FILTER_DEFLATE.

Platforms tested:
    Tested h5committest {arabica (fortran), eirene (fortran, C++)
	modi4 (parallel, fortran)}
    FreeBSD 4.7 (sleipnir)
2002-11-20 08:03:55 -05:00
Bill Wendling
ceba60418c [svn-r5807] Purpose:
Update, Bug Fix, and Feature Add
Description:
    - Updated how AC_{ENABLE,WITH} help messages were being generated.
      Autoconf now gives you an AC_HELP_STRING macro to use to create
      them.

    - Fixed the problem with Linux LFS on RedHat 7.3 machines. It wasn't
      finding getdents64(), so we can't rely on that being present
      anymore...

    - Added GPFS detection and setting.

    - Updated how compression is specified. It's no longer necessary to
      test for HAVE_ZLIB_H, HAVE_LIBZ, and HAVE_COMPRESS2. The one macro
      {H5_}HAVE_COMPRESSION takes care of all of these.
Solution:
    Changed the check for Linux LFS from looking for getdents() to
    looking at the version number of the kernel (using the uname -r
    command). You can still override with the --enable-linux-lfs switch
    if you really believe that your <2.4 kernel has LFS support.
Platforms tested:
    Linux (2.2 and 2.4)
2002-07-17 11:10:46 -05:00
Binh-Minh Ribler
c84ad4179d [svn-r4604]
Purpose:
    Fixing found bug
Description:
    A data file cannot be removed because the corresponding H5File object
    is still in existence, which means the data file is still opened.
Solution:
    Moved h5_cleanup to outside of the try block so that the H5File object
    will go out of scope and be destroyed before h5_cleanup attempts to
    remove the corresponding data file.
Platforms tested:
    SunOS 5.7 (arabica)
    Windows 98
2001-11-13 17:15:47 -05:00
Binh-Minh Ribler
6f26403376 [svn-r3708] Purpose: Code cleanup and adding more test
Description:
    dsets.cpp:
	- Added routine's headers to be consistent with the C tests
	- Added the following tests (they are not in the C version
	test because they are C++ specific):
	    + Test copying a user-defined type using DataType::copy
	    + Test copying a user-defined type using DataType::operator=
	    + Test copying a user-defined int type using DataType::operator=
	    + Test copying an integer predefined type using a constructor
	    + Test copying an integer predefined type using DataType::operator=

    th5s.cpp:
	- Added routine's headers to be consistent with the C tests
	- Cleanup old couts and statements used during debugging

Platforms tested:
    arabica (sparc-sun-solaris 2.7)
2001-03-24 23:54:15 -05:00
Binh-Minh Ribler
014152842b [svn-r3625]
Purpose:
    Format and typos mostly
Description:
    Changed the "Copyright" header of some files so they will be consistent.
Platforms tested:
    arabica (sparc-sun-solaris 2.7)
2001-03-14 08:27:13 -05:00
Binh-Minh Ribler
f9d785f7de [svn-r3582]
Purpose:
    Test code improvement
Description:
	- Added H5_HAVE_ZLIB_H and H5_HAVE_LIBZ to dsets.cpp
	- Added the use of new API Exception::getCFuncName to obtain
	the name of the function where failure occurs, to various places
	in the test code.

Platforms tested:
	arabica (sparc-sun-solaris 2.7)
2001-03-09 17:15:28 -05:00
Binh-Minh Ribler
4811d326ef [svn-r3551]
Purpose:
    Bug fix
Description:
    Compiled error about "RcsId initialized twice"
Solution:
    This problem has been taken care of in the C++ API already.  However,
    because dsets.cpp includes the C++ header file H5Cpp.h after the
    C test header files, h5test.h and testhdf5.h, the fix was missed.
    Moved H5Cpp.h to before those C header files.
Platforms tested:
    arabica (sparc-sun-solaris 2.7)
2001-03-06 02:14:12 -05:00
Bill Wendling
e99887cc66 [svn-r3549] Purpose:
Adding Test
Description:
    - Add the tests to the Makefile so that they'll be executed.
    - Fixed a few bugs in dsets.cpp
        * Some buffers should have been char *'s instead of void *'s.
        * An iterator for a loop wasn't declared properly.
    - Formatting changes
Solution:
    - Changed the void *'s to char *'s.
    - Declared the loop iterator.

    NOTE: Doesn't work just yet. There's a conflict with a C++ keyword
    (delete) in the H5Pprivate.h header file. Quincey's looking into
    this.
Platforms tested:
    Linux
2001-03-05 18:09:59 -05:00
Binh-Minh Ribler
6e7877db5e [svn-r3532] Purpose:
Adding tests to the C++ API
Description:
    The C++ API has no formal testing yet.
Solution:
    Added tests for file and dataset interfaces.  I'm still working on
    other tests.
Platforms tested:
    Linux (gcc version egcs-2.91.66)
    I temporarily modified the Makefile on my local Linux machine and these
    tests work.  I need Bill to help adding them permanently before I can
    test on an NCSA machine.  I checked the files in now so Bill can do that.
2001-03-01 13:07:25 -05:00