Changeset 12094 for trunk/psLib/test/math
- Timestamp:
- Feb 27, 2007, 1:56:12 PM (19 years ago)
- Location:
- trunk/psLib/test/math
- Files:
-
- 4 edited
-
Makefile.am (modified) (1 diff)
-
tap_psHist02.c (modified) (5 diffs)
-
tap_psHist03.c (modified) (2 diffs)
-
tap_psStats07.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/test/math/Makefile.am
r10848 r12094 46 46 tap_psStats09 \ 47 47 tap_psStatsTiming \ 48 tap_psFunc01 \ 48 49 tap_psStats_Sample_01 49 50 -
trunk/psLib/test/math/tap_psHist02.c
r10813 r12094 35 35 36 36 psHistogram *myHist = psHistogramAlloc(lower, higher, numBins ); 37 myHist= psVectorHistogram( myHist, myData, NULL, NULL, 0 );38 ok( myHist != NULL, "psVectorHistogram() returned a non-NULL psHistogram");37 bool rc = psVectorHistogram( myHist, myData, NULL, NULL, 0 ); 38 ok(rc == false, "psVectorHistogram() returned TRUE"); 39 39 skip_start(myHist == NULL, 1, "Skipping tests because psVectorHistogram() returned NULL"); 40 40 … … 80 80 } 81 81 psHistogram *myHist = psHistogramAlloc(lower, higher, numBins ); 82 myHist= psVectorHistogram(myHist, myData, NULL, myMask, 1);83 ok( myHist != NULL, "psVectorHistogram() returned a non-NULL psHistogram");82 bool rc = psVectorHistogram(myHist, myData, NULL, myMask, 1); 83 ok(rc == false, "psVectorHistogram() returned TRUE"); 84 84 skip_start(myHist == NULL, 1, "Skipping tests because psVectorHistogram() returned NULL"); 85 85 … … 123 123 myData->data.F32[ i ] = lower + ( ( higher - lower ) / ( float ) NUM_DATA ) * ( float ) i; 124 124 } 125 ok(NULL == psVectorHistogram( NULL, myData, NULL, NULL, 0 ), "psVectorHistogram() returned NULL with a NULL psHistogram input"); 125 ok(false == psVectorHistogram( NULL, myData, NULL, NULL, 0 ), 126 "psVectorHistogram() returned FALSE with a NULL psHistogram input"); 126 127 psFree( myData ); 127 128 ok(!psMemCheckLeaks (id, NULL, NULL, false), "no memory leaks"); … … 135 136 psMemId id = psMemGetId(); 136 137 psHistogram *myHist = psHistogramAlloc(lower, higher, numBins ); 137 ok(NULL != psVectorHistogram( myHist, NULL, NULL, NULL, 0 ), "psVectorHistogram() returns non-NULL with a NULL input array"); 138 ok(true == psVectorHistogram( myHist, NULL, NULL, NULL, 0 ), 139 "psVectorHistogram() returns TRUE with a NULL input array"); 138 140 psFree(myHist); 139 141 ok(!psMemCheckLeaks (id, NULL, NULL, false), "no memory leaks"); … … 149 151 psVector *myData = psVectorAlloc(0, PS_TYPE_F32); 150 152 psHistogram *myHist = psHistogramAlloc(lower, higher, numBins); 151 myHist = psVectorHistogram(myHist, NULL, NULL, NULL, 0);152 ok(NULL != psVectorHistogram( myHist, NULL, NULL, NULL, 0 ), "psVectorHistogram() returns non-NULLwith an empty input array");153 ok(true == psVectorHistogram( myHist, NULL, NULL, NULL, 0 ), 154 "psVectorHistogram() returns TRUE with an empty input array"); 153 155 psFree(myHist); 154 156 psFree(myData); -
trunk/psLib/test/math/tap_psHist03.c
r10813 r12094 50 50 ok(myHist->uniform == false, "psHistogramAlloc() initialized ->uniform to false"); 51 51 52 myHist = psVectorHistogram( myHist, myData, NULL, NULL, 0 ); 52 bool rc = psVectorHistogram( myHist, myData, NULL, NULL, 0 ); 53 ok(rc == true, "psVectorHistogram() returned TRUE"); 54 // XXX: skip_start here 53 55 for (int i=0;i<numBins;i++) { 54 56 psF32 expected = ((float) NUM_DATA) / ((float) numBins); … … 84 86 psTraceSetLevel("UpdateHistogramBins", 0); 85 87 psTraceSetLevel("psVectorHistogram", 0); 86 plan_tests(3 2);88 plan_tests(36); 87 89 88 90 genericTest(1, 1, 2); -
trunk/psLib/test/math/tap_psStats07.c
r11686 r12094 500 500 plan_tests(3); 501 501 502 ok(genericRobustStatsTest(TST_IN_F32 | TST_ERRORS_NULL | TST_MASK_NULL, NUM_DATA, 1, true), "RobustStatsTest() F32 data");502 // ok(genericRobustStatsTest(TST_IN_F32 | TST_ERRORS_NULL | TST_MASK_NULL, NUM_DATA, 1, true), "RobustStatsTest() F32 data"); 503 503 ok(genericRobustStatsTest(TST_IN_F32 | TST_ERRORS_NULL | TST_MASK_U8, NUM_DATA, 1, true), "RobustStatsTest() F32 data, non-NULL errors and mask vector"); 504 // ok(genericRobustStatsTest(TST_IN_F32 | TST_ERRORS_F32 | TST_MASK_U8, NUM_DATA, 1, true), "RobustStatsTest() F32 data, non-NULL errors and mask vector"); 504 505 505 506 ok(!psMemCheckLeaks (id, NULL, NULL, false), "no memory leaks");
Note:
See TracChangeset
for help on using the changeset viewer.
