IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 10753 for trunk/ippdb/tests


Ignore:
Timestamp:
Dec 15, 2006, 12:38:13 PM (20 years ago)
Author:
jhoblitt
Message:

VERSION to 0.0.68

Location:
trunk/ippdb/tests
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippdb/tests/alloc.c

    r10748 r10753  
    15311531
    15321532    {
    1533         p4PStackedImfileRow *object;
    1534 
    1535         object = p4PStackedImfileRowAlloc(-32, "a string", "a string", "a string", "a string"    );
     1533        p4StackedImfileRow *object;
     1534
     1535        object = p4StackedImfileRowAlloc(-32, "a string", "a string", "a string", "a string"    );
    15361536
    15371537        if (!object) {
     
    15641564
    15651565    {
    1566         p4PDiffImfileRow *object;
    1567 
    1568         object = p4PDiffImfileRowAlloc(-32, "a string", -32, "a string", "a string", "a string", "a string"    );
     1566        p4DiffImfileRow *object;
     1567
     1568        object = p4DiffImfileRowAlloc(-32, "a string", -32, "a string", "a string", "a string", "a string"    );
    15691569
    15701570        if (!object) {
     
    16051605
    16061606    {
    1607         p4PMagicMaskImfileRow *object;
    1608 
    1609         object = p4PMagicMaskImfileRowAlloc(-32, "a string", -32, "a string", "a string"    );
     1607        p4MagicMaskImfileRow *object;
     1608
     1609        object = p4MagicMaskImfileRowAlloc(-32, "a string", -32, "a string", "a string"    );
    16101610
    16111611        if (!object) {
  • trunk/ippdb/tests/createtable.c

    r10748 r10753  
    538538        }
    539539
    540         if(!p4PStackedImfileCreateTable(dbh)) {
    541             exit(EXIT_FAILURE);
    542         }
    543 
    544         psDBCleanup(dbh);
    545     }
    546 
    547     {
    548         psDB            *dbh;
    549 
    550         dbh = psDBInit("localhost", "test", NULL, "test");
    551         if (!dbh) {
    552             exit(EXIT_FAILURE);
    553         }
    554 
    555         if(!p4PDiffImfileCreateTable(dbh)) {
    556             exit(EXIT_FAILURE);
    557         }
    558 
    559         psDBCleanup(dbh);
    560     }
    561 
    562     {
    563         psDB            *dbh;
    564 
    565         dbh = psDBInit("localhost", "test", NULL, "test");
    566         if (!dbh) {
    567             exit(EXIT_FAILURE);
    568         }
    569 
    570         if(!p4PMagicMaskImfileCreateTable(dbh)) {
     540        if(!p4StackedImfileCreateTable(dbh)) {
     541            exit(EXIT_FAILURE);
     542        }
     543
     544        psDBCleanup(dbh);
     545    }
     546
     547    {
     548        psDB            *dbh;
     549
     550        dbh = psDBInit("localhost", "test", NULL, "test");
     551        if (!dbh) {
     552            exit(EXIT_FAILURE);
     553        }
     554
     555        if(!p4DiffImfileCreateTable(dbh)) {
     556            exit(EXIT_FAILURE);
     557        }
     558
     559        psDBCleanup(dbh);
     560    }
     561
     562    {
     563        psDB            *dbh;
     564
     565        dbh = psDBInit("localhost", "test", NULL, "test");
     566        if (!dbh) {
     567            exit(EXIT_FAILURE);
     568        }
     569
     570        if(!p4MagicMaskImfileCreateTable(dbh)) {
    571571            exit(EXIT_FAILURE);
    572572        }
  • trunk/ippdb/tests/dbcleanup.c

    r10748 r10753  
    4646    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4InputImfile");
    4747    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4WarpedImfile");
    48     p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4PStackedImfile");
    49     p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4PDiffImfile");
    50     p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4PMagicMaskImfile");
     48    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4StackedImfile");
     49    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4DiffImfile");
     50    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4MagicMaskImfile");
    5151
    5252    psDBCleanup(dbh);
  • trunk/ippdb/tests/dbsetup.c

    r10748 r10753  
    118118    p4WarpedImfileCreateTable(dbh);
    119119
    120     p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4PStackedImfile");
    121     p4PStackedImfileCreateTable(dbh);
     120    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4StackedImfile");
     121    p4StackedImfileCreateTable(dbh);
    122122
    123     p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4PDiffImfile");
    124     p4PDiffImfileCreateTable(dbh);
     123    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4DiffImfile");
     124    p4DiffImfileCreateTable(dbh);
    125125
    126     p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4PMagicMaskImfile");
    127     p4PMagicMaskImfileCreateTable(dbh);
     126    p_psDBRunQuery(dbh, "DROP TABLE IF EXISTS p4MagicMaskImfile");
     127    p4MagicMaskImfileCreateTable(dbh);
    128128
    129129    psDBCleanup(dbh);
  • trunk/ippdb/tests/droptable.c

    r10748 r10753  
    538538        }
    539539
    540         if (!p4PStackedImfileDropTable(dbh)) {
    541             exit(EXIT_FAILURE);
    542         }
    543 
    544         psDBCleanup(dbh);
    545     }
    546 
    547     {
    548         psDB            *dbh;
    549 
    550         dbh = psDBInit("localhost", "test", NULL, "test");
    551         if (!dbh) {
    552             exit(EXIT_FAILURE);
    553         }
    554 
    555         if (!p4PDiffImfileDropTable(dbh)) {
    556             exit(EXIT_FAILURE);
    557         }
    558 
    559         psDBCleanup(dbh);
    560     }
    561 
    562     {
    563         psDB            *dbh;
    564 
    565         dbh = psDBInit("localhost", "test", NULL, "test");
    566         if (!dbh) {
    567             exit(EXIT_FAILURE);
    568         }
    569 
    570         if (!p4PMagicMaskImfileDropTable(dbh)) {
     540        if (!p4StackedImfileDropTable(dbh)) {
     541            exit(EXIT_FAILURE);
     542        }
     543
     544        psDBCleanup(dbh);
     545    }
     546
     547    {
     548        psDB            *dbh;
     549
     550        dbh = psDBInit("localhost", "test", NULL, "test");
     551        if (!dbh) {
     552            exit(EXIT_FAILURE);
     553        }
     554
     555        if (!p4DiffImfileDropTable(dbh)) {
     556            exit(EXIT_FAILURE);
     557        }
     558
     559        psDBCleanup(dbh);
     560    }
     561
     562    {
     563        psDB            *dbh;
     564
     565        dbh = psDBInit("localhost", "test", NULL, "test");
     566        if (!dbh) {
     567            exit(EXIT_FAILURE);
     568        }
     569
     570        if (!p4MagicMaskImfileDropTable(dbh)) {
    571571            exit(EXIT_FAILURE);
    572572        }
  • trunk/ippdb/tests/insert.c

    r10748 r10753  
    538538        }
    539539
    540         if (!p4PStackedImfileInsert(dbh, -32, "a string", "a string", "a string", "a string")) {
    541             exit(EXIT_FAILURE);
    542         }
    543 
    544         psDBCleanup(dbh);
    545     }
    546 
    547     {
    548         psDB            *dbh;
    549 
    550         dbh = psDBInit("localhost", "test", NULL, "test");
    551         if (!dbh) {
    552             exit(EXIT_FAILURE);
    553         }
    554 
    555         if (!p4PDiffImfileInsert(dbh, -32, "a string", -32, "a string", "a string", "a string", "a string")) {
    556             exit(EXIT_FAILURE);
    557         }
    558 
    559         psDBCleanup(dbh);
    560     }
    561 
    562     {
    563         psDB            *dbh;
    564 
    565         dbh = psDBInit("localhost", "test", NULL, "test");
    566         if (!dbh) {
    567             exit(EXIT_FAILURE);
    568         }
    569 
    570         if (!p4PMagicMaskImfileInsert(dbh, -32, "a string", -32, "a string", "a string")) {
     540        if (!p4StackedImfileInsert(dbh, -32, "a string", "a string", "a string", "a string")) {
     541            exit(EXIT_FAILURE);
     542        }
     543
     544        psDBCleanup(dbh);
     545    }
     546
     547    {
     548        psDB            *dbh;
     549
     550        dbh = psDBInit("localhost", "test", NULL, "test");
     551        if (!dbh) {
     552            exit(EXIT_FAILURE);
     553        }
     554
     555        if (!p4DiffImfileInsert(dbh, -32, "a string", -32, "a string", "a string", "a string", "a string")) {
     556            exit(EXIT_FAILURE);
     557        }
     558
     559        psDBCleanup(dbh);
     560    }
     561
     562    {
     563        psDB            *dbh;
     564
     565        dbh = psDBInit("localhost", "test", NULL, "test");
     566        if (!dbh) {
     567            exit(EXIT_FAILURE);
     568        }
     569
     570        if (!p4MagicMaskImfileInsert(dbh, -32, "a string", -32, "a string", "a string")) {
    571571            exit(EXIT_FAILURE);
    572572        }
  • trunk/ippdb/tests/insertfits.c

    r10748 r10753  
    934934        }
    935935
    936         if (!p4PStackedImfileInsertFits(dbh, fits)) {
    937             exit(EXIT_FAILURE);
    938         }
    939 
    940         if (!psFitsClose(fits)) {
    941             exit(EXIT_FAILURE);
    942         }
    943 
    944         psDBCleanup(dbh);
    945     }
    946 
    947     {
    948         psDB            *dbh;
    949         psFits          *fits;
    950 
    951         dbh = psDBInit("localhost", "test", NULL, "test");
    952         if (!dbh) {
    953             exit(EXIT_FAILURE);
    954         }
    955 
    956         // open a temp
    957         fits = psFitsOpen(TMP_FILENAME, "r");
    958         if (!fits) {
    959             exit(EXIT_FAILURE);
    960         }
    961 
    962         if (!p4PDiffImfileInsertFits(dbh, fits)) {
    963             exit(EXIT_FAILURE);
    964         }
    965 
    966         if (!psFitsClose(fits)) {
    967             exit(EXIT_FAILURE);
    968         }
    969 
    970         psDBCleanup(dbh);
    971     }
    972 
    973     {
    974         psDB            *dbh;
    975         psFits          *fits;
    976 
    977         dbh = psDBInit("localhost", "test", NULL, "test");
    978         if (!dbh) {
    979             exit(EXIT_FAILURE);
    980         }
    981 
    982         // open a temp
    983         fits = psFitsOpen(TMP_FILENAME, "r");
    984         if (!fits) {
    985             exit(EXIT_FAILURE);
    986         }
    987 
    988         if (!p4PMagicMaskImfileInsertFits(dbh, fits)) {
     936        if (!p4StackedImfileInsertFits(dbh, fits)) {
     937            exit(EXIT_FAILURE);
     938        }
     939
     940        if (!psFitsClose(fits)) {
     941            exit(EXIT_FAILURE);
     942        }
     943
     944        psDBCleanup(dbh);
     945    }
     946
     947    {
     948        psDB            *dbh;
     949        psFits          *fits;
     950
     951        dbh = psDBInit("localhost", "test", NULL, "test");
     952        if (!dbh) {
     953            exit(EXIT_FAILURE);
     954        }
     955
     956        // open a temp
     957        fits = psFitsOpen(TMP_FILENAME, "r");
     958        if (!fits) {
     959            exit(EXIT_FAILURE);
     960        }
     961
     962        if (!p4DiffImfileInsertFits(dbh, fits)) {
     963            exit(EXIT_FAILURE);
     964        }
     965
     966        if (!psFitsClose(fits)) {
     967            exit(EXIT_FAILURE);
     968        }
     969
     970        psDBCleanup(dbh);
     971    }
     972
     973    {
     974        psDB            *dbh;
     975        psFits          *fits;
     976
     977        dbh = psDBInit("localhost", "test", NULL, "test");
     978        if (!dbh) {
     979            exit(EXIT_FAILURE);
     980        }
     981
     982        // open a temp
     983        fits = psFitsOpen(TMP_FILENAME, "r");
     984        if (!fits) {
     985            exit(EXIT_FAILURE);
     986        }
     987
     988        if (!p4MagicMaskImfileInsertFits(dbh, fits)) {
    989989            exit(EXIT_FAILURE);
    990990        }
  • trunk/ippdb/tests/insertobject.c

    r10748 r10753  
    777777    {
    778778        psDB            *dbh;
    779         p4PStackedImfileRow *object;
    780 
    781         dbh = psDBInit("localhost", "test", NULL, "test");
    782         if (!dbh) {
    783             exit(EXIT_FAILURE);
    784         }
    785 
    786         object = p4PStackedImfileRowAlloc(-32, "a string", "a string", "a string", "a string");
    787         if (!object) {
    788             exit(EXIT_FAILURE);
    789         }
    790 
    791         if (!p4PStackedImfileInsertObject(dbh, object)) {
    792             exit(EXIT_FAILURE);
    793         }
    794 
    795         psFree(object);
    796         psDBCleanup(dbh);
    797     }
    798 
    799     {
    800         psDB            *dbh;
    801         p4PDiffImfileRow *object;
    802 
    803         dbh = psDBInit("localhost", "test", NULL, "test");
    804         if (!dbh) {
    805             exit(EXIT_FAILURE);
    806         }
    807 
    808         object = p4PDiffImfileRowAlloc(-32, "a string", -32, "a string", "a string", "a string", "a string");
    809         if (!object) {
    810             exit(EXIT_FAILURE);
    811         }
    812 
    813         if (!p4PDiffImfileInsertObject(dbh, object)) {
    814             exit(EXIT_FAILURE);
    815         }
    816 
    817         psFree(object);
    818         psDBCleanup(dbh);
    819     }
    820 
    821     {
    822         psDB            *dbh;
    823         p4PMagicMaskImfileRow *object;
    824 
    825         dbh = psDBInit("localhost", "test", NULL, "test");
    826         if (!dbh) {
    827             exit(EXIT_FAILURE);
    828         }
    829 
    830         object = p4PMagicMaskImfileRowAlloc(-32, "a string", -32, "a string", "a string");
    831         if (!object) {
    832             exit(EXIT_FAILURE);
    833         }
    834 
    835         if (!p4PMagicMaskImfileInsertObject(dbh, object)) {
     779        p4StackedImfileRow *object;
     780
     781        dbh = psDBInit("localhost", "test", NULL, "test");
     782        if (!dbh) {
     783            exit(EXIT_FAILURE);
     784        }
     785
     786        object = p4StackedImfileRowAlloc(-32, "a string", "a string", "a string", "a string");
     787        if (!object) {
     788            exit(EXIT_FAILURE);
     789        }
     790
     791        if (!p4StackedImfileInsertObject(dbh, object)) {
     792            exit(EXIT_FAILURE);
     793        }
     794
     795        psFree(object);
     796        psDBCleanup(dbh);
     797    }
     798
     799    {
     800        psDB            *dbh;
     801        p4DiffImfileRow *object;
     802
     803        dbh = psDBInit("localhost", "test", NULL, "test");
     804        if (!dbh) {
     805            exit(EXIT_FAILURE);
     806        }
     807
     808        object = p4DiffImfileRowAlloc(-32, "a string", -32, "a string", "a string", "a string", "a string");
     809        if (!object) {
     810            exit(EXIT_FAILURE);
     811        }
     812
     813        if (!p4DiffImfileInsertObject(dbh, object)) {
     814            exit(EXIT_FAILURE);
     815        }
     816
     817        psFree(object);
     818        psDBCleanup(dbh);
     819    }
     820
     821    {
     822        psDB            *dbh;
     823        p4MagicMaskImfileRow *object;
     824
     825        dbh = psDBInit("localhost", "test", NULL, "test");
     826        if (!dbh) {
     827            exit(EXIT_FAILURE);
     828        }
     829
     830        object = p4MagicMaskImfileRowAlloc(-32, "a string", -32, "a string", "a string");
     831        if (!object) {
     832            exit(EXIT_FAILURE);
     833        }
     834
     835        if (!p4MagicMaskImfileInsertObject(dbh, object)) {
    836836            exit(EXIT_FAILURE);
    837837        }
  • trunk/ippdb/tests/metadatafromobject.c

    r10748 r10753  
    18121812    {
    18131813        psMetadata      *md;
    1814         p4PStackedImfileRow *object;
    1815         bool            status;
    1816 
    1817         object = p4PStackedImfileRowAlloc(-32, "a string", "a string", "a string", "a string");
    1818         if (!object) {
    1819             exit(EXIT_FAILURE);
    1820         }
    1821 
    1822         md = p4PStackedImfileMetadataFromObject(object);
     1814        p4StackedImfileRow *object;
     1815        bool            status;
     1816
     1817        object = p4StackedImfileRowAlloc(-32, "a string", "a string", "a string", "a string");
     1818        if (!object) {
     1819            exit(EXIT_FAILURE);
     1820        }
     1821
     1822        md = p4StackedImfileMetadataFromObject(object);
    18231823        if (!md) {
    18241824            exit(EXIT_FAILURE);
     
    18531853    {
    18541854        psMetadata      *md;
    1855         p4PDiffImfileRow *object;
    1856         bool            status;
    1857 
    1858         object = p4PDiffImfileRowAlloc(-32, "a string", -32, "a string", "a string", "a string", "a string");
    1859         if (!object) {
    1860             exit(EXIT_FAILURE);
    1861         }
    1862 
    1863         md = p4PDiffImfileMetadataFromObject(object);
     1855        p4DiffImfileRow *object;
     1856        bool            status;
     1857
     1858        object = p4DiffImfileRowAlloc(-32, "a string", -32, "a string", "a string", "a string", "a string");
     1859        if (!object) {
     1860            exit(EXIT_FAILURE);
     1861        }
     1862
     1863        md = p4DiffImfileMetadataFromObject(object);
    18641864        if (!md) {
    18651865            exit(EXIT_FAILURE);
     
    19021902    {
    19031903        psMetadata      *md;
    1904         p4PMagicMaskImfileRow *object;
    1905         bool            status;
    1906 
    1907         object = p4PMagicMaskImfileRowAlloc(-32, "a string", -32, "a string", "a string");
    1908         if (!object) {
    1909             exit(EXIT_FAILURE);
    1910         }
    1911 
    1912         md = p4PMagicMaskImfileMetadataFromObject(object);
     1904        p4MagicMaskImfileRow *object;
     1905        bool            status;
     1906
     1907        object = p4MagicMaskImfileRowAlloc(-32, "a string", -32, "a string", "a string");
     1908        if (!object) {
     1909            exit(EXIT_FAILURE);
     1910        }
     1911
     1912        md = p4MagicMaskImfileMetadataFromObject(object);
    19131913        if (!md) {
    19141914            exit(EXIT_FAILURE);
  • trunk/ippdb/tests/objectfrommetadata.c

    r10748 r10753  
    27742774    {
    27752775        psMetadata      *md;
    2776         p4PStackedImfileRow *object;
     2776        p4StackedImfileRow *object;
    27772777
    27782778        md = psMetadataAlloc();
     
    27982798        }
    27992799
    2800         object = p4PStackedImfileObjectFromMetadata(md);
     2800        object = p4StackedImfileObjectFromMetadata(md);
    28012801        if (!object) {
    28022802            psFree(md);
     
    28322832    {
    28332833        psMetadata      *md;
    2834         p4PDiffImfileRow *object;
     2834        p4DiffImfileRow *object;
    28352835
    28362836        md = psMetadataAlloc();
     
    28642864        }
    28652865
    2866         object = p4PDiffImfileObjectFromMetadata(md);
     2866        object = p4DiffImfileObjectFromMetadata(md);
    28672867        if (!object) {
    28682868            psFree(md);
     
    29062906    {
    29072907        psMetadata      *md;
    2908         p4PMagicMaskImfileRow *object;
     2908        p4MagicMaskImfileRow *object;
    29092909
    29102910        md = psMetadataAlloc();
     
    29302930        }
    29312931
    2932         object = p4PMagicMaskImfileObjectFromMetadata(md);
     2932        object = p4MagicMaskImfileObjectFromMetadata(md);
    29332933        if (!object) {
    29342934            psFree(md);
  • trunk/ippdb/tests/selectrowsfits.c

    r10748 r10753  
    791791        }
    792792
    793         if (!p4PStackedImfileSelectRowsFits(dbh, fits, NULL, 1)) {
    794             exit(EXIT_FAILURE);
    795         }
    796 
    797         psFree(fits);
    798         psDBCleanup(dbh);
    799     }
    800 
    801     {
    802         psDB            *dbh;
    803         psFits          *fits;
    804 
    805         dbh = psDBInit("localhost", "test", NULL, "test");
    806         if (!dbh) {
    807             exit(EXIT_FAILURE);
    808         }
    809 
    810         fits = psFitsOpen(TMP_FILENAME, "w");
    811         if (!fits) {
    812             exit(EXIT_FAILURE);
    813         }
    814 
    815         if (!p4PDiffImfileSelectRowsFits(dbh, fits, NULL, 1)) {
    816             exit(EXIT_FAILURE);
    817         }
    818 
    819         psFree(fits);
    820         psDBCleanup(dbh);
    821     }
    822 
    823     {
    824         psDB            *dbh;
    825         psFits          *fits;
    826 
    827         dbh = psDBInit("localhost", "test", NULL, "test");
    828         if (!dbh) {
    829             exit(EXIT_FAILURE);
    830         }
    831 
    832         fits = psFitsOpen(TMP_FILENAME, "w");
    833         if (!fits) {
    834             exit(EXIT_FAILURE);
    835         }
    836 
    837         if (!p4PMagicMaskImfileSelectRowsFits(dbh, fits, NULL, 1)) {
     793        if (!p4StackedImfileSelectRowsFits(dbh, fits, NULL, 1)) {
     794            exit(EXIT_FAILURE);
     795        }
     796
     797        psFree(fits);
     798        psDBCleanup(dbh);
     799    }
     800
     801    {
     802        psDB            *dbh;
     803        psFits          *fits;
     804
     805        dbh = psDBInit("localhost", "test", NULL, "test");
     806        if (!dbh) {
     807            exit(EXIT_FAILURE);
     808        }
     809
     810        fits = psFitsOpen(TMP_FILENAME, "w");
     811        if (!fits) {
     812            exit(EXIT_FAILURE);
     813        }
     814
     815        if (!p4DiffImfileSelectRowsFits(dbh, fits, NULL, 1)) {
     816            exit(EXIT_FAILURE);
     817        }
     818
     819        psFree(fits);
     820        psDBCleanup(dbh);
     821    }
     822
     823    {
     824        psDB            *dbh;
     825        psFits          *fits;
     826
     827        dbh = psDBInit("localhost", "test", NULL, "test");
     828        if (!dbh) {
     829            exit(EXIT_FAILURE);
     830        }
     831
     832        fits = psFitsOpen(TMP_FILENAME, "w");
     833        if (!fits) {
     834            exit(EXIT_FAILURE);
     835        }
     836
     837        if (!p4MagicMaskImfileSelectRowsFits(dbh, fits, NULL, 1)) {
    838838            exit(EXIT_FAILURE);
    839839        }
Note: See TracChangeset for help on using the changeset viewer.