IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 3084


Ignore:
Timestamp:
Jan 24, 2005, 3:02:23 PM (21 years ago)
Author:
evanalst
Message:

Update test case for psListGetNext and psListGetPrevious.

Location:
trunk/psLib/test/collections
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/collections/tst_psList.c

    r3083 r3084  
    66 *  @author Robert DeSonia, MHPCC
    77 *
    8  *  @version $Revision: 1.24 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2005-01-25 00:13:12 $
     8 *  @version $Revision: 1.25 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2005-01-25 01:02:23 $
    1010 *
    1111 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    942942    }
    943943
     944    // Attempt to get next with NULL iterator
     945    if ( psListGetNext(NULL) != NULL ) {
     946        psError(PS_ERR_UNKNOWN,true,"Did not return NULL when NULL iterator specified");
     947        return 24;
     948    }
     949
     950    // Attempt to get previous with NULL iterator
     951    if( psListGetPrevious(NULL) != NULL) {
     952        psError(PS_ERR_UNKNOWN,true,"Did not return NULL when NULL iterator specified");
     953        return 25;
     954    }
    944955
    945956    // 3. set list.cursor to list.tail if where=PS_LIST_TAIL
     
    9931004        psError(PS_ERR_UNKNOWN, true,"psListGetPrevious moved cursor beyond head.");
    9941005        return 15;
     1006    }
     1007    if (psListGetNext(iter) != NULL) {
     1008        psError(PS_ERR_UNKNOWN,true,"psListGetNext should return NULL when above head");
     1009        return 22;
     1010    }
     1011    if (*(psS32*)psListGetNext(iter) != 0 ) {
     1012        psError(PS_ERR_UNKNOWN,true,"psListGetNext didn't move cursor to next.");
     1013        return 23;
    9951014    }
    9961015
  • trunk/psLib/test/collections/verified/tst_psList.stderr

    r3083 r3084  
    9696<DATE><TIME>|<HOST>|I|testListIterator
    9797     psListSetIterator/psListGetNext/psListGetPrev shall move the list cursor to the specified location
     98<DATE><TIME>|<HOST>|W|psListGetPrevious
     99    Attempt to get previous with itertator cursor NULL and offEnd false
    98100
    99101---> TESTPOINT PASSED (psList{psListIterator} | tst_psList.c)
Note: See TracChangeset for help on using the changeset viewer.