IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 2981


Ignore:
Timestamp:
Jan 13, 2005, 11:45:13 AM (22 years ago)
Author:
evanalst
Message:

Update the test driver for print invalid metadata type.

Location:
trunk/psLib/test
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/astronomy/tst_psMetadata_05.c

    r2636 r2981  
    2222*  @author  Ross Harman, MHPCC
    2323*
    24 *  @version $Revision: 1.14 $  $Name: not supported by cvs2svn $
    25 *  @date  $Date: 2004-12-06 19:59:39 $
     24*  @version $Revision: 1.15 $  $Name: not supported by cvs2svn $
     25*  @date  $Date: 2005-01-13 21:45:13 $
    2626*
    2727*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    167167
    168168    if (psMetadataItemPrint(fd, "S32 = %ld\n", item2) == false) {
    169         printf("ERROR: Return type should be trye\n");
     169        printf("ERROR: Return type should be true\n");
    170170        return 10;
    171171    }
    172172
    173173    if (psMetadataItemPrint(fd, "BOL = %ld\n", item3) == false) {
    174         printf("ERROR: Return type should be trye\n");
     174        printf("ERROR: Return type should be true\n");
    175175        return 11;
    176176    }
    177177
    178178    if (psMetadataItemPrint(fd, "F32 = %g\n", item5) == false) {
    179         printf("ERROR: Return type should be trye\n");
     179        printf("ERROR: Return type should be true\n");
    180180        return 12;
    181181    }
    182182
    183183    if (psMetadataItemPrint(fd, "F64 = %g\n", item6) == false) {
    184         printf("ERROR: Return type should be trye\n");
     184        printf("ERROR: Return type should be true\n");
    185185        return 13;
    186186    }
    187187
    188188    if (psMetadataItemPrint(fd, "STR = %s\n", item7) == false) {
    189         printf("ERROR: Return type should be trye\n");
     189        printf("ERROR: Return type should be true\n");
    190190        return 14;
    191191    }
    192 
    193     if (psMetadataItemPrint(fd, "UNK = \n", item8) == false) {
    194         printf("ERROR: Return type should be trye\n");
     192    psLogMsg(__func__,PS_LOG_INFO,"Attempt to print item of invalid type, should generate error message");
     193    if (psMetadataItemPrint(fd, "UNK = \n", item8) == true) {
     194        printf("ERROR: Return type should be false\n");
     195        fclose(fd);
    195196        return 15;
    196197    }
  • trunk/psLib/test/astronomy/verified/tst_psMetadata_05.stderr

    r2613 r2981  
     1<DATE><TIME>|<HOST>|I|main
     2    Attempt to print item of invalid type, should generate error message
    13<DATE><TIME>|<HOST>|E|psMetadataItemPrint (psMetadataIO.c:<LINENO>)
    24    Specified psMetadataType, 10, is not supported.
  • trunk/psLib/test/collections/tst_psMetadata_05.c

    r2636 r2981  
    2222*  @author  Ross Harman, MHPCC
    2323*
    24 *  @version $Revision: 1.14 $  $Name: not supported by cvs2svn $
    25 *  @date  $Date: 2004-12-06 19:59:39 $
     24*  @version $Revision: 1.15 $  $Name: not supported by cvs2svn $
     25*  @date  $Date: 2005-01-13 21:45:13 $
    2626*
    2727*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    167167
    168168    if (psMetadataItemPrint(fd, "S32 = %ld\n", item2) == false) {
    169         printf("ERROR: Return type should be trye\n");
     169        printf("ERROR: Return type should be true\n");
    170170        return 10;
    171171    }
    172172
    173173    if (psMetadataItemPrint(fd, "BOL = %ld\n", item3) == false) {
    174         printf("ERROR: Return type should be trye\n");
     174        printf("ERROR: Return type should be true\n");
    175175        return 11;
    176176    }
    177177
    178178    if (psMetadataItemPrint(fd, "F32 = %g\n", item5) == false) {
    179         printf("ERROR: Return type should be trye\n");
     179        printf("ERROR: Return type should be true\n");
    180180        return 12;
    181181    }
    182182
    183183    if (psMetadataItemPrint(fd, "F64 = %g\n", item6) == false) {
    184         printf("ERROR: Return type should be trye\n");
     184        printf("ERROR: Return type should be true\n");
    185185        return 13;
    186186    }
    187187
    188188    if (psMetadataItemPrint(fd, "STR = %s\n", item7) == false) {
    189         printf("ERROR: Return type should be trye\n");
     189        printf("ERROR: Return type should be true\n");
    190190        return 14;
    191191    }
    192 
    193     if (psMetadataItemPrint(fd, "UNK = \n", item8) == false) {
    194         printf("ERROR: Return type should be trye\n");
     192    psLogMsg(__func__,PS_LOG_INFO,"Attempt to print item of invalid type, should generate error message");
     193    if (psMetadataItemPrint(fd, "UNK = \n", item8) == true) {
     194        printf("ERROR: Return type should be false\n");
     195        fclose(fd);
    195196        return 15;
    196197    }
Note: See TracChangeset for help on using the changeset viewer.