Changeset 4887 for trunk/psLib/test/mathtypes
- Timestamp:
- Aug 26, 2005, 1:01:17 PM (21 years ago)
- Location:
- trunk/psLib/test/mathtypes
- Files:
-
- 4 edited
-
tst_psImage.c (modified) (2 diffs)
-
tst_psVector.c (modified) (4 diffs)
-
verified/tst_psImage.stderr (modified) (1 diff)
-
verified/tst_psVector.stderr (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/test/mathtypes/tst_psImage.c
r4886 r4887 6 6 * @author Robert DeSonia, MHPCC 7 7 * 8 * @version $Revision: 1. 2$ $Name: not supported by cvs2svn $9 * @date $Date: 2005-08-26 03:35:03$8 * @version $Revision: 1.3 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2005-08-26 23:01:17 $ 10 10 * 11 11 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 328 328 int nCol = 1; 329 329 in1 = psImageAlloc(nRow, nCol, PS_TYPE_U8); 330 if ( !psImageInit(in1, 1 ) ) {330 if ( !psImageInit(in1, -1 ) ) { 331 331 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "ImageInit failed. U8 Case - 1x1\n"); 332 332 } -
trunk/psLib/test/mathtypes/tst_psVector.c
r4547 r4887 14 14 * @author Ross Harman, MHPCC 15 15 * 16 * @version $Revision: 1. 1$ $Name: not supported by cvs2svn $17 * @date $Date: 2005-0 7-13 02:47:00$16 * @version $Revision: 1.2 $ $Name: not supported by cvs2svn $ 17 * @date $Date: 2005-08-26 23:01:17 $ 18 18 * 19 19 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 27 27 static psS32 testVectorRealloc(void); 28 28 static psS32 testVectorExtend(void); 29 static psS32 testVectorInit(void); 29 30 30 31 testDescription tests[] = { … … 32 33 {testVectorRealloc,-2,"psVectorRealloc",0,false}, 33 34 {testVectorExtend,-3,"psVectorExtend",0,false}, 35 {testVectorInit,-4,"psVectorInit",0,false}, 34 36 {NULL} 35 37 }; … … 270 272 return 0; 271 273 } 274 275 psS32 testVectorInit(void) 276 { 277 psVector *in1 = NULL; 278 psVector *in2 = NULL; 279 psVector *in3 = NULL; 280 psVector *in4 = NULL; 281 psVector *in5 = NULL; 282 psVector *in6 = NULL; 283 psVector *in7 = NULL; 284 psVector *in8 = NULL; 285 psVector *in9 = NULL; 286 psVector *in10 = NULL; 287 psVector *in11 = NULL; 288 psVector *in12 = NULL; 289 int nalloc = 1; 290 in1 = psVectorAlloc(nalloc, PS_TYPE_U8); 291 in2 = psVectorAlloc(nalloc, PS_TYPE_U16); 292 in3 = psVectorAlloc(nalloc, PS_TYPE_U32); 293 in4 = psVectorAlloc(nalloc, PS_TYPE_U64); 294 in5 = psVectorAlloc(nalloc, PS_TYPE_S8); 295 in6 = psVectorAlloc(nalloc, PS_TYPE_S16); 296 in7 = psVectorAlloc(nalloc, PS_TYPE_S32); 297 in8 = psVectorAlloc(nalloc, PS_TYPE_S64); 298 in9 = psVectorAlloc(nalloc, PS_TYPE_F32); 299 in10 = psVectorAlloc(nalloc, PS_TYPE_F64); 300 in11 = psVectorAlloc(nalloc, PS_TYPE_C32); 301 in12 = psVectorAlloc(nalloc, PS_TYPE_C64); 302 psC32 vC32; 303 psC64 vC64; 304 305 if ( !psVectorInit(in1, 1 ) ) { 306 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. U8 Case \n"); 307 } 308 if ( !psVectorInit(in2, PS_MAX_U64) ) { 309 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. U16 Case \n"); 310 } 311 if ( !psVectorInit(in3, 10) ) { 312 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. U32 Case \n"); 313 } 314 if ( !psVectorInit(in4, -1) ) { 315 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. U64 Case \n"); 316 } 317 if ( !psVectorInit(in5, PS_MAX_S16 ) ) { 318 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. S8 Case \n"); 319 } 320 if ( !psVectorInit(in6, -100 ) ) { 321 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. S16 Case \n"); 322 } 323 if ( !psVectorInit(in7, 1 ) ) { 324 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. S32 Case \n"); 325 } 326 if ( !psVectorInit(in8, PS_MAX_U64 ) ) { 327 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. S64 Case \n"); 328 } 329 if ( !psVectorInit(in9, 1.1 ) ) { 330 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. F32 Case \n"); 331 } 332 if ( !psVectorInit(in10, 1.4 ) ) { 333 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. F64 Case \n"); 334 } 335 336 vC32 = 1.23 + 1.19I; 337 vC64 = 2.13 + 2.31I; 338 if ( !psVectorInit(in11, vC32 ) ) { 339 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. C32 Case \n"); 340 } 341 if ( !psVectorInit(in12, vC64 ) ) { 342 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "VectorInit failed. C64 Case \n"); 343 } 344 345 psFree(in1); 346 psFree(in2); 347 psFree(in3); 348 psFree(in4); 349 psFree(in5); 350 psFree(in6); 351 psFree(in7); 352 psFree(in8); 353 psFree(in9); 354 psFree(in10); 355 psFree(in11); 356 psFree(in12); 357 return 0; 358 } -
trunk/psLib/test/mathtypes/verified/tst_psImage.stderr
r4886 r4887 122 122 123 123 <DATE><TIME>|<HOST>|E|psImageInit (FILE:LINENO) 124 Error: U8 Value out of Range. 125 <DATE><TIME>|<HOST>|E|testImageInit (FILE:LINENO) 126 ImageInit failed. U8 Case - 1x1 127 <DATE><TIME>|<HOST>|E|psImageInit (FILE:LINENO) 124 128 datatype 260 not defined in psImageInit 125 129 <DATE><TIME>|<HOST>|E|testImageInit (FILE:LINENO) -
trunk/psLib/test/mathtypes/verified/tst_psVector.stderr
r4547 r4887 32 32 ---> TESTPOINT PASSED (psVector{psVectorExtend} | tst_psVector.c) 33 33 34 /***************************** TESTPOINT ******************************************\ 35 * TestFile: tst_psVector.c * 36 * TestPoint: psVector{psVectorInit} * 37 * TestType: Positive * 38 \**********************************************************************************/ 39 40 <DATE><TIME>|<HOST>|E|psVectorInit (FILE:LINENO) 41 Error: U16 Value out of Range. 42 <DATE><TIME>|<HOST>|E|testVectorInit (FILE:LINENO) 43 VectorInit failed. U16 Case 44 <DATE><TIME>|<HOST>|E|psVectorInit (FILE:LINENO) 45 Error: S8 Value out of Range. 46 <DATE><TIME>|<HOST>|E|testVectorInit (FILE:LINENO) 47 VectorInit failed. S8 Case 48 49 ---> TESTPOINT PASSED (psVector{psVectorInit} | tst_psVector.c) 50
Note:
See TracChangeset
for help on using the changeset viewer.
