IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 21, 2007, 5:14:51 PM (19 years ago)
Author:
jhoblitt
Message:

VERSION 1.1.19

File:
1 edited

Legend:

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

    r12426 r12535  
    447447    {
    448448        psDB            *dbh;
     449        warpRunRow      *object;
     450
     451        dbh = psDBInit("localhost", "test", NULL, "test");
     452        if (!dbh) {
     453            exit(EXIT_FAILURE);
     454        }
     455
     456        object = warpRunRowAlloc(-64, "a string", "a string", "a string", "a string", "0001-01-01T00:00:00Z");
     457        if (!object) {
     458            exit(EXIT_FAILURE);
     459        }
     460
     461        if (!warpRunInsertObject(dbh, object)) {
     462            exit(EXIT_FAILURE);
     463        }
     464
     465        psFree(object);
     466        psDBCleanup(dbh);
     467    }
     468
     469    {
     470        psDB            *dbh;
     471        warpInputExpRow *object;
     472
     473        dbh = psDBInit("localhost", "test", NULL, "test");
     474        if (!dbh) {
     475            exit(EXIT_FAILURE);
     476        }
     477
     478        object = warpInputExpRowAlloc(-64, -64, true);
     479        if (!object) {
     480            exit(EXIT_FAILURE);
     481        }
     482
     483        if (!warpInputExpInsertObject(dbh, object)) {
     484            exit(EXIT_FAILURE);
     485        }
     486
     487        psFree(object);
     488        psDBCleanup(dbh);
     489    }
     490
     491    {
     492        psDB            *dbh;
     493        warpSkyCellMapRow *object;
     494
     495        dbh = psDBInit("localhost", "test", NULL, "test");
     496        if (!dbh) {
     497            exit(EXIT_FAILURE);
     498        }
     499
     500        object = warpSkyCellMapRowAlloc(-64, "a string", "a string", -64, "a string", -16);
     501        if (!object) {
     502            exit(EXIT_FAILURE);
     503        }
     504
     505        if (!warpSkyCellMapInsertObject(dbh, object)) {
     506            exit(EXIT_FAILURE);
     507        }
     508
     509        psFree(object);
     510        psDBCleanup(dbh);
     511    }
     512
     513    {
     514        psDB            *dbh;
     515        warpSkyfileRow  *object;
     516
     517        dbh = psDBInit("localhost", "test", NULL, "test");
     518        if (!dbh) {
     519            exit(EXIT_FAILURE);
     520        }
     521
     522        object = warpSkyfileRowAlloc(-64, "a string", "a string", "a string", 64.64, 64.64);
     523        if (!object) {
     524            exit(EXIT_FAILURE);
     525        }
     526
     527        if (!warpSkyfileInsertObject(dbh, object)) {
     528            exit(EXIT_FAILURE);
     529        }
     530
     531        psFree(object);
     532        psDBCleanup(dbh);
     533    }
     534
     535    {
     536        psDB            *dbh;
     537        diffRunRow      *object;
     538
     539        dbh = psDBInit("localhost", "test", NULL, "test");
     540        if (!dbh) {
     541            exit(EXIT_FAILURE);
     542        }
     543
     544        object = diffRunRowAlloc(-64, "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", "a string");
     545        if (!object) {
     546            exit(EXIT_FAILURE);
     547        }
     548
     549        if (!diffRunInsertObject(dbh, object)) {
     550            exit(EXIT_FAILURE);
     551        }
     552
     553        psFree(object);
     554        psDBCleanup(dbh);
     555    }
     556
     557    {
     558        psDB            *dbh;
     559        diffInputSkyfileRow *object;
     560
     561        dbh = psDBInit("localhost", "test", NULL, "test");
     562        if (!dbh) {
     563            exit(EXIT_FAILURE);
     564        }
     565
     566        object = diffInputSkyfileRowAlloc(-64, -64, "a string", "a string", "a string", true);
     567        if (!object) {
     568            exit(EXIT_FAILURE);
     569        }
     570
     571        if (!diffInputSkyfileInsertObject(dbh, object)) {
     572            exit(EXIT_FAILURE);
     573        }
     574
     575        psFree(object);
     576        psDBCleanup(dbh);
     577    }
     578
     579    {
     580        psDB            *dbh;
     581        diffSkyfileRow  *object;
     582
     583        dbh = psDBInit("localhost", "test", NULL, "test");
     584        if (!dbh) {
     585            exit(EXIT_FAILURE);
     586        }
     587
     588        object = diffSkyfileRowAlloc(-64, "a string", 64.64, 64.64);
     589        if (!object) {
     590            exit(EXIT_FAILURE);
     591        }
     592
     593        if (!diffSkyfileInsertObject(dbh, object)) {
     594            exit(EXIT_FAILURE);
     595        }
     596
     597        psFree(object);
     598        psDBCleanup(dbh);
     599    }
     600
     601    {
     602        psDB            *dbh;
     603        stackRunRow     *object;
     604
     605        dbh = psDBInit("localhost", "test", NULL, "test");
     606        if (!dbh) {
     607            exit(EXIT_FAILURE);
     608        }
     609
     610        object = stackRunRowAlloc(-64, "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", "a string");
     611        if (!object) {
     612            exit(EXIT_FAILURE);
     613        }
     614
     615        if (!stackRunInsertObject(dbh, object)) {
     616            exit(EXIT_FAILURE);
     617        }
     618
     619        psFree(object);
     620        psDBCleanup(dbh);
     621    }
     622
     623    {
     624        psDB            *dbh;
     625        stackInputSkyfileRow *object;
     626
     627        dbh = psDBInit("localhost", "test", NULL, "test");
     628        if (!dbh) {
     629            exit(EXIT_FAILURE);
     630        }
     631
     632        object = stackInputSkyfileRowAlloc(-64, -64);
     633        if (!object) {
     634            exit(EXIT_FAILURE);
     635        }
     636
     637        if (!stackInputSkyfileInsertObject(dbh, object)) {
     638            exit(EXIT_FAILURE);
     639        }
     640
     641        psFree(object);
     642        psDBCleanup(dbh);
     643    }
     644
     645    {
     646        psDB            *dbh;
     647        stackSumSkyfileRow *object;
     648
     649        dbh = psDBInit("localhost", "test", NULL, "test");
     650        if (!dbh) {
     651            exit(EXIT_FAILURE);
     652        }
     653
     654        object = stackSumSkyfileRowAlloc(-64, "a string", 64.64, 64.64);
     655        if (!object) {
     656            exit(EXIT_FAILURE);
     657        }
     658
     659        if (!stackSumSkyfileInsertObject(dbh, object)) {
     660            exit(EXIT_FAILURE);
     661        }
     662
     663        psFree(object);
     664        psDBCleanup(dbh);
     665    }
     666
     667    {
     668        psDB            *dbh;
    449669        detRunRow       *object;
    450670
     
    680900
    681901        if (!detRunSummaryInsertObject(dbh, object)) {
    682             exit(EXIT_FAILURE);
    683         }
    684 
    685         psFree(object);
    686         psDBCleanup(dbh);
    687     }
    688 
    689     {
    690         psDB            *dbh;
    691         warpRunRow      *object;
    692 
    693         dbh = psDBInit("localhost", "test", NULL, "test");
    694         if (!dbh) {
    695             exit(EXIT_FAILURE);
    696         }
    697 
    698         object = warpRunRowAlloc(-64, "a string", "a string", "a string", "a string", "0001-01-01T00:00:00Z");
    699         if (!object) {
    700             exit(EXIT_FAILURE);
    701         }
    702 
    703         if (!warpRunInsertObject(dbh, object)) {
    704             exit(EXIT_FAILURE);
    705         }
    706 
    707         psFree(object);
    708         psDBCleanup(dbh);
    709     }
    710 
    711     {
    712         psDB            *dbh;
    713         warpInputExpRow *object;
    714 
    715         dbh = psDBInit("localhost", "test", NULL, "test");
    716         if (!dbh) {
    717             exit(EXIT_FAILURE);
    718         }
    719 
    720         object = warpInputExpRowAlloc(-64, -64, true);
    721         if (!object) {
    722             exit(EXIT_FAILURE);
    723         }
    724 
    725         if (!warpInputExpInsertObject(dbh, object)) {
    726             exit(EXIT_FAILURE);
    727         }
    728 
    729         psFree(object);
    730         psDBCleanup(dbh);
    731     }
    732 
    733     {
    734         psDB            *dbh;
    735         warpSkyCellMapRow *object;
    736 
    737         dbh = psDBInit("localhost", "test", NULL, "test");
    738         if (!dbh) {
    739             exit(EXIT_FAILURE);
    740         }
    741 
    742         object = warpSkyCellMapRowAlloc(-64, "a string", "a string", -64, "a string", -16);
    743         if (!object) {
    744             exit(EXIT_FAILURE);
    745         }
    746 
    747         if (!warpSkyCellMapInsertObject(dbh, object)) {
    748             exit(EXIT_FAILURE);
    749         }
    750 
    751         psFree(object);
    752         psDBCleanup(dbh);
    753     }
    754 
    755     {
    756         psDB            *dbh;
    757         warpSkyfileRow  *object;
    758 
    759         dbh = psDBInit("localhost", "test", NULL, "test");
    760         if (!dbh) {
    761             exit(EXIT_FAILURE);
    762         }
    763 
    764         object = warpSkyfileRowAlloc(-64, "a string", "a string", "a string", 64.64, 64.64);
    765         if (!object) {
    766             exit(EXIT_FAILURE);
    767         }
    768 
    769         if (!warpSkyfileInsertObject(dbh, object)) {
    770             exit(EXIT_FAILURE);
    771         }
    772 
    773         psFree(object);
    774         psDBCleanup(dbh);
    775     }
    776 
    777     {
    778         psDB            *dbh;
    779         diffRunRow      *object;
    780 
    781         dbh = psDBInit("localhost", "test", NULL, "test");
    782         if (!dbh) {
    783             exit(EXIT_FAILURE);
    784         }
    785 
    786         object = diffRunRowAlloc(-64, "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", "a string");
    787         if (!object) {
    788             exit(EXIT_FAILURE);
    789         }
    790 
    791         if (!diffRunInsertObject(dbh, object)) {
    792             exit(EXIT_FAILURE);
    793         }
    794 
    795         psFree(object);
    796         psDBCleanup(dbh);
    797     }
    798 
    799     {
    800         psDB            *dbh;
    801         diffInputSkyfileRow *object;
    802 
    803         dbh = psDBInit("localhost", "test", NULL, "test");
    804         if (!dbh) {
    805             exit(EXIT_FAILURE);
    806         }
    807 
    808         object = diffInputSkyfileRowAlloc(-64, -64, "a string", "a string", "a string", true);
    809         if (!object) {
    810             exit(EXIT_FAILURE);
    811         }
    812 
    813         if (!diffInputSkyfileInsertObject(dbh, object)) {
    814             exit(EXIT_FAILURE);
    815         }
    816 
    817         psFree(object);
    818         psDBCleanup(dbh);
    819     }
    820 
    821     {
    822         psDB            *dbh;
    823         diffSkyfileRow  *object;
    824 
    825         dbh = psDBInit("localhost", "test", NULL, "test");
    826         if (!dbh) {
    827             exit(EXIT_FAILURE);
    828         }
    829 
    830         object = diffSkyfileRowAlloc(-64, "a string", 64.64, 64.64);
    831         if (!object) {
    832             exit(EXIT_FAILURE);
    833         }
    834 
    835         if (!diffSkyfileInsertObject(dbh, object)) {
    836             exit(EXIT_FAILURE);
    837         }
    838 
    839         psFree(object);
    840         psDBCleanup(dbh);
    841     }
    842 
    843     {
    844         psDB            *dbh;
    845         stackRunRow     *object;
    846 
    847         dbh = psDBInit("localhost", "test", NULL, "test");
    848         if (!dbh) {
    849             exit(EXIT_FAILURE);
    850         }
    851 
    852         object = stackRunRowAlloc(-64, "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", "a string");
    853         if (!object) {
    854             exit(EXIT_FAILURE);
    855         }
    856 
    857         if (!stackRunInsertObject(dbh, object)) {
    858             exit(EXIT_FAILURE);
    859         }
    860 
    861         psFree(object);
    862         psDBCleanup(dbh);
    863     }
    864 
    865     {
    866         psDB            *dbh;
    867         stackInputSkyfileRow *object;
    868 
    869         dbh = psDBInit("localhost", "test", NULL, "test");
    870         if (!dbh) {
    871             exit(EXIT_FAILURE);
    872         }
    873 
    874         object = stackInputSkyfileRowAlloc(-64, -64);
    875         if (!object) {
    876             exit(EXIT_FAILURE);
    877         }
    878 
    879         if (!stackInputSkyfileInsertObject(dbh, object)) {
    880             exit(EXIT_FAILURE);
    881         }
    882 
    883         psFree(object);
    884         psDBCleanup(dbh);
    885     }
    886 
    887     {
    888         psDB            *dbh;
    889         stackSumSkyfileRow *object;
    890 
    891         dbh = psDBInit("localhost", "test", NULL, "test");
    892         if (!dbh) {
    893             exit(EXIT_FAILURE);
    894         }
    895 
    896         object = stackSumSkyfileRowAlloc(-64, "a string", 64.64, 64.64);
    897         if (!object) {
    898             exit(EXIT_FAILURE);
    899         }
    900 
    901         if (!stackSumSkyfileInsertObject(dbh, object)) {
    902902            exit(EXIT_FAILURE);
    903903        }
Note: See TracChangeset for help on using the changeset viewer.