mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-02-17 16:10:24 +08:00
[svn-r12418] Purpose: Maintenance/new feature
Description: Added new tests for the h5stat tool; added --version flag to the h5stat tool to display library version information Solution: Platforms tested: heping, shanti Misc. update:
This commit is contained in:
parent
b73313b3d4
commit
09aa1fa82c
@ -101,7 +101,7 @@ static int display_dset = FALSE;
|
||||
static int display_dtype_metadata = FALSE;
|
||||
static int display_dtype = FALSE;
|
||||
|
||||
static const char *s_opts ="FfhGgDdT";
|
||||
static const char *s_opts ="FfhGgDdTV";
|
||||
static struct long_options l_opts[] = {
|
||||
{"help", no_arg, 'h'},
|
||||
{"hel", no_arg, 'h'},
|
||||
@ -149,6 +149,12 @@ static struct long_options l_opts[] = {
|
||||
{"dtypeme", no_arg, 'T'},
|
||||
{"dtypem", no_arg, 'T'},
|
||||
{"dtype", no_arg, 'T'},
|
||||
{ "version", no_arg, 'V' },
|
||||
{ "versio", no_arg, 'V' },
|
||||
{ "versi", no_arg, 'V' },
|
||||
{ "vers", no_arg, 'V' },
|
||||
{ "ver", no_arg, 'V' },
|
||||
{ "ve", no_arg, 'V' },
|
||||
{ NULL, 0, '\0' }
|
||||
};
|
||||
|
||||
@ -174,6 +180,7 @@ static void
|
||||
fprintf(stdout, "\n");
|
||||
fprintf(stdout, " OPTIONS\n");
|
||||
fprintf(stdout, " -h, --help Print a usage message and exit\n");
|
||||
fprintf(stdout, " -V, --version Print version number and exit\n");
|
||||
fprintf(stdout, " -f, --file Print file information\n");
|
||||
fprintf(stdout, " -F, --filemetadata Print file metadata\n");
|
||||
fprintf(stdout, " -g, --group Print group information\n");
|
||||
@ -659,6 +666,11 @@ parse_start:
|
||||
case 'h':
|
||||
usage(progname);
|
||||
leave(EXIT_SUCCESS);
|
||||
case 'V':
|
||||
print_version(progname);
|
||||
leave(EXIT_SUCCESS);
|
||||
break;
|
||||
|
||||
default:
|
||||
usage(progname);
|
||||
leave(EXIT_FAILURE);
|
||||
|
@ -106,9 +106,18 @@ SKIP() {
|
||||
##############################################################################
|
||||
##############################################################################
|
||||
|
||||
# test for help flag
|
||||
# Test for help flag
|
||||
TOOLTEST h5stat_help1.ddl -h
|
||||
TOOLTEST h5stat_help2.ddl --help
|
||||
|
||||
# Test file with groups, compressed datasets, user-applied fileters, etc.
|
||||
# h5stat_filters.h5 is a copy of ../../testfiles/tfilters.h5 as of release 1.8.0-alpha4
|
||||
TOOLTEST h5stat_filters.ddl h5stat_filters.h5
|
||||
TOOLTEST h5stat_filters-f.ddl -f h5stat_filters.h5
|
||||
TOOLTEST h5stat_filters-F.ddl -F h5stat_filters.h5
|
||||
TOOLTEST h5stat_filters-d.ddl -d h5stat_filters.h5
|
||||
TOOLTEST h5stat_filters-g.ddl -g h5stat_filters.h5
|
||||
TOOLTEST h5stat_filters-dT.ddl -dT h5stat_filters.h5
|
||||
echo
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user