diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2004-01-10 01:41:34 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2004-01-10 01:41:34 (GMT) |
commit | 7f6fbe6b604423782f6195b809a23c32d0bd1863 (patch) | |
tree | e8c77f2aec3dbc365983995305864e47c5119b18 /test/ttst.c | |
parent | c891e4a01e575cec23d51b526fd792b57eab9d06 (diff) | |
download | hdf5-7f6fbe6b604423782f6195b809a23c32d0bd1863.zip hdf5-7f6fbe6b604423782f6195b809a23c32d0bd1863.tar.gz hdf5-7f6fbe6b604423782f6195b809a23c32d0bd1863.tar.bz2 |
[svn-r8049] Purpose:
Code cleanup & reorganization
Description:
Move further in the testing framework cleanup, eliminating all the
global variables (moving them into testframe.c as static variables) from the
testing framework code and moving it into the libh5test.a.
Platforms tested:
FreeBSD 4.9 (sleipnir) w & w/o thread-safety, c++ & parallel
h5committested
Diffstat (limited to 'test/ttst.c')
-rw-r--r-- | test/ttst.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/test/ttst.c b/test/ttst.c index 9632cb7..ca45d9b 100644 --- a/test/ttst.c +++ b/test/ttst.c @@ -209,16 +209,14 @@ test_tst_insert(void) CHECK(found, NULL, "H5ST_find"); if(HDstrcmp((const char *)found->eqkid,uniq_words[u])) { - num_errs++; - printf("%d: TST node values don't match!, found->eqkid=%s, uniq_words[%u]=%s\n",__LINE__,(char *)found->eqkid,(unsigned)u,uniq_words[u]); + TestErrPrintf("%d: TST node values don't match!, found->eqkid=%s, uniq_words[%u]=%s\n",__LINE__,(char *)found->eqkid,(unsigned)u,uniq_words[u]); } /* end if */ obj=H5ST_locate(tree,uniq_words[u]); CHECK(obj, NULL, "H5ST_locate"); if(HDstrcmp((const char *)obj,uniq_words[u])) { - num_errs++; - printf("%d: TST objects don't match!, obj=%s, uniq_words[%u]=%s\n",__LINE__,(char *)obj,(unsigned)u,uniq_words[u]); + TestErrPrintf("%d: TST objects don't match!, obj=%s, uniq_words[%u]=%s\n",__LINE__,(char *)obj,(unsigned)u,uniq_words[u]); } /* end if */ } /* end for */ @@ -269,8 +267,7 @@ test_tst_iterate(void) do { /* Check that the strings in the TST are in the correct order */ if(HDstrcmp((const char *)found->eqkid,sort_uniq_words[u])) { - num_errs++; - printf("%d: TST node values don't match!, found->eqkid=%s, sort_uniq_words[%u]=%s\n",__LINE__,(char *)found->eqkid,(unsigned)u,sort_uniq_words[u]); + TestErrPrintf("%d: TST node values don't match!, found->eqkid=%s, sort_uniq_words[%u]=%s\n",__LINE__,(char *)found->eqkid,(unsigned)u,sort_uniq_words[u]); } /* end if */ /* Advance to next string in TST */ @@ -319,8 +316,7 @@ test_tst_remove(void) /* Check that the correct string was removed from TST */ if(HDstrcmp((const char *)obj,rand_uniq_words[u])) { - num_errs++; - printf("%d: TST node values don't match!, obj=%s, rand_uniq_words[%u]=%s\n",__LINE__,(char *)obj,(unsigned)u,rand_uniq_words[u]); + TestErrPrintf("%d: TST node values don't match!, obj=%s, rand_uniq_words[%u]=%s\n",__LINE__,(char *)obj,(unsigned)u,rand_uniq_words[u]); } /* end if */ /* Check that the string can't be found in the TST any longer */ @@ -342,8 +338,7 @@ test_tst_remove(void) /* Check that the correct object will be removed from TST */ if(HDstrcmp((const char *)found->eqkid,rand_uniq_words[u])) { - num_errs++; - printf("%d: TST node values don't match!, found->eqkid=%s, rand_uniq_words[%u]=%s\n",__LINE__,(char *)found->eqkid,(unsigned)u,rand_uniq_words[u]); + TestErrPrintf("%d: TST node values don't match!, found->eqkid=%s, rand_uniq_words[%u]=%s\n",__LINE__,(char *)found->eqkid,(unsigned)u,rand_uniq_words[u]); } /* end if */ /* Remove the node */ |