Changeset 14061 for trunk/ippdb/tests/insertobject.c
- Timestamp:
- Jul 6, 2007, 4:55:04 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/ippdb/tests/insertobject.c (modified) (16 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippdb/tests/insertobject.c
r13937 r14061 7 7 { 8 8 psDB *dbh; 9 expTagCounterRow *object;10 11 dbh = psDBInit("localhost", "test", NULL, "test");12 if (!dbh) {13 exit(EXIT_FAILURE);14 }15 16 object = expTagCounterRowAlloc(64);17 if (!object) {18 exit(EXIT_FAILURE);19 }20 21 if (!expTagCounterInsertObject(dbh, object)) {22 exit(EXIT_FAILURE);23 }24 25 psFree(object);26 psDBCleanup(dbh);27 }28 29 {30 psDB *dbh;31 9 summitExpRow *object; 32 10 … … 102 80 } 103 81 104 object = pzPendingImfileRowAlloc("a string", "a string", "a string", "a string", "a string", "a string");82 object = pzPendingImfileRowAlloc("a string", "a string", "a string", "a string", "a string", -64); 105 83 if (!object) { 106 84 exit(EXIT_FAILURE); … … 146 124 } 147 125 148 object = pzDoneImfileRowAlloc("a string", "a string", "a string", "a string", "a string", "a string", "a string");126 object = pzDoneImfileRowAlloc("a string", "a string", "a string", "a string", "a string", -64, "a string"); 149 127 if (!object) { 150 128 exit(EXIT_FAILURE); … … 168 146 } 169 147 170 object = newExpRowAlloc( "a string", "a string", "a string", "a string", -32, "a string");148 object = newExpRowAlloc(-64, "a string", "a string", "a string", "a string", "a string", "a string"); 171 149 if (!object) { 172 150 exit(EXIT_FAILURE); … … 190 168 } 191 169 192 object = newImfileRowAlloc( "a string", "a string", "a string", "a string");170 object = newImfileRowAlloc(-64, "a string", "a string"); 193 171 if (!object) { 194 172 exit(EXIT_FAILURE); … … 212 190 } 213 191 214 object = rawExpRowAlloc( "a string", "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", -32, "a string", "a string", "a string", 32.32, 64.64, 64.64, 32.32, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", 32.32, -16);192 object = rawExpRowAlloc(-64, "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", "a string", "a string", "a string", "a string", 32.32, 64.64, 64.64, 32.32, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", 32.32, -16); 215 193 if (!object) { 216 194 exit(EXIT_FAILURE); … … 234 212 } 235 213 236 object = rawImfileRowAlloc( "a string", "a string", "a string", "a string", "a string", "a string", 32.32, 64.64, 64.64, 32.32, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", "0001-01-01T00:00:00Z", -16);214 object = rawImfileRowAlloc(-64, "a string", "a string", "a string", "0001-01-01T00:00:00Z", "a string", "a string", "a string", "a string", "a string", "a string", 32.32, 64.64, 64.64, 32.32, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 32.32, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16); 237 215 if (!object) { 238 216 exit(EXIT_FAILURE); … … 256 234 } 257 235 258 object = guidePendingExpRowAlloc(-64, "a string", "a string");236 object = guidePendingExpRowAlloc(-64, -64, "a string"); 259 237 if (!object) { 260 238 exit(EXIT_FAILURE); … … 271 249 { 272 250 psDB *dbh; 273 chip PendingExpRow*object;274 275 dbh = psDBInit("localhost", "test", NULL, "test"); 276 if (!dbh) { 277 exit(EXIT_FAILURE); 278 } 279 280 object = chip PendingExpRowAlloc(-64, "a string", -64, "a string", "a string", "a string", "a string", "a string");281 if (!object) { 282 exit(EXIT_FAILURE); 283 } 284 285 if (!chip PendingExpInsertObject(dbh, object)) {286 exit(EXIT_FAILURE); 287 } 288 289 psFree(object); 290 psDBCleanup(dbh); 291 } 292 293 { 294 psDB *dbh; 295 chip PendingImfileRow *object;296 297 dbh = psDBInit("localhost", "test", NULL, "test"); 298 if (!dbh) { 299 exit(EXIT_FAILURE); 300 } 301 302 object = chip PendingImfileRowAlloc(-64, "a string", "a string");303 if (!object) { 304 exit(EXIT_FAILURE); 305 } 306 307 if (!chip PendingImfileInsertObject(dbh, object)) {308 exit(EXIT_FAILURE); 309 } 310 311 psFree(object); 312 psDBCleanup(dbh); 313 } 314 315 { 316 psDB *dbh; 317 chipProcessed ExpRow *object;318 319 dbh = psDBInit("localhost", "test", NULL, "test"); 320 if (!dbh) { 321 exit(EXIT_FAILURE); 322 } 323 324 object = chipProcessed ExpRowAlloc(-64, "a string", -64, "a string", "a string", "a string", "a string", "a string");325 if (!object) { 326 exit(EXIT_FAILURE); 327 } 328 329 if (!chipProcessed ExpInsertObject(dbh, object)) {251 chipRunRow *object; 252 253 dbh = psDBInit("localhost", "test", NULL, "test"); 254 if (!dbh) { 255 exit(EXIT_FAILURE); 256 } 257 258 object = chipRunRowAlloc(-64, "a string", "a string", "a string", "a string", "a string", "a string", "a string"); 259 if (!object) { 260 exit(EXIT_FAILURE); 261 } 262 263 if (!chipRunInsertObject(dbh, object)) { 264 exit(EXIT_FAILURE); 265 } 266 267 psFree(object); 268 psDBCleanup(dbh); 269 } 270 271 { 272 psDB *dbh; 273 chipInputImfileRow *object; 274 275 dbh = psDBInit("localhost", "test", NULL, "test"); 276 if (!dbh) { 277 exit(EXIT_FAILURE); 278 } 279 280 object = chipInputImfileRowAlloc(-64, -64, "a string"); 281 if (!object) { 282 exit(EXIT_FAILURE); 283 } 284 285 if (!chipInputImfileInsertObject(dbh, object)) { 286 exit(EXIT_FAILURE); 287 } 288 289 psFree(object); 290 psDBCleanup(dbh); 291 } 292 293 { 294 psDB *dbh; 295 chipProcessedImfileRow *object; 296 297 dbh = psDBInit("localhost", "test", NULL, "test"); 298 if (!dbh) { 299 exit(EXIT_FAILURE); 300 } 301 302 object = chipProcessedImfileRowAlloc(-64, -64, "a string", "a string", 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, -32, -32, -32, -32, "a string", -16); 303 if (!object) { 304 exit(EXIT_FAILURE); 305 } 306 307 if (!chipProcessedImfileInsertObject(dbh, object)) { 330 308 exit(EXIT_FAILURE); 331 309 } … … 359 337 { 360 338 psDB *dbh; 361 chipProcessedImfileRow *object; 362 363 dbh = psDBInit("localhost", "test", NULL, "test"); 364 if (!dbh) { 365 exit(EXIT_FAILURE); 366 } 367 368 object = chipProcessedImfileRowAlloc(-64, "a string", "a string", 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, -32, -32, -32, -32, "a string", -16); 369 if (!object) { 370 exit(EXIT_FAILURE); 371 } 372 373 if (!chipProcessedImfileInsertObject(dbh, object)) { 374 exit(EXIT_FAILURE); 375 } 376 377 psFree(object); 378 psDBCleanup(dbh); 379 } 380 381 { 382 psDB *dbh; 383 camPendingExpRow *object; 384 385 dbh = psDBInit("localhost", "test", NULL, "test"); 386 if (!dbh) { 387 exit(EXIT_FAILURE); 388 } 389 390 object = camPendingExpRowAlloc(-64, -64, "a string", "a string", "a string", "a string", "a string"); 391 if (!object) { 392 exit(EXIT_FAILURE); 393 } 394 395 if (!camPendingExpInsertObject(dbh, object)) { 339 camRunRow *object; 340 341 dbh = psDBInit("localhost", "test", NULL, "test"); 342 if (!dbh) { 343 exit(EXIT_FAILURE); 344 } 345 346 object = camRunRowAlloc(-64, -64, "a string", "a string", "a string", "a string", "a string", "a string", "a string"); 347 if (!object) { 348 exit(EXIT_FAILURE); 349 } 350 351 if (!camRunInsertObject(dbh, object)) { 396 352 exit(EXIT_FAILURE); 397 353 } … … 410 366 } 411 367 412 object = camProcessedExpRowAlloc(-64, -64, "a string", "a string", "a string", "a string", "a string", "a string",32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, -32, -32, -32, -32, "a string", -16);368 object = camProcessedExpRowAlloc(-64, -64, "a string", 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32, -32, -32, -32, -32, "a string", -16); 413 369 if (!object) { 414 370 exit(EXIT_FAILURE); … … 696 652 } 697 653 698 object = detInputExpRowAlloc(-64, -32, "a string", true);654 object = detInputExpRowAlloc(-64, -32, -64, true); 699 655 if (!object) { 700 656 exit(EXIT_FAILURE); … … 718 674 } 719 675 720 object = detProcessedImfileRowAlloc(-64, "a string", "a string", "a string", "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16);676 object = detProcessedImfileRowAlloc(-64, -64, "a string", "a string", "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16); 721 677 if (!object) { 722 678 exit(EXIT_FAILURE); … … 740 696 } 741 697 742 object = detProcessedExpRowAlloc(-64, "a string", "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16);698 object = detProcessedExpRowAlloc(-64, -64, "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16); 743 699 if (!object) { 744 700 exit(EXIT_FAILURE); … … 850 806 } 851 807 852 object = detResidImfileRowAlloc(-64, -32, "a string", "a string", "a string", "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16);808 object = detResidImfileRowAlloc(-64, -32, -64, "a string", "a string", "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", -16); 853 809 if (!object) { 854 810 exit(EXIT_FAILURE); … … 872 828 } 873 829 874 object = detResidExpRowAlloc(-64, -32, "a string", "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", true, -16);830 object = detResidExpRowAlloc(-64, -32, -64, "a string", 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, 64.64, "a string", true, -16); 875 831 if (!object) { 876 832 exit(EXIT_FAILURE);
Note:
See TracChangeset
for help on using the changeset viewer.
