Revision 20014 trunk/libraries/libDataSourceDBBaseDrivers/src-test/org/gvsig/data/datastores/vectorial/db/jdbc/h2/H2Test.java

View differences:

H2Test.java
236 236

  
237 237
		assertEquals(9, fc.size());
238 238

  
239
		fc.dispose();
240

  
239 241
		assertFalse("Edition allowed in sqlSource mode", fs.isEditable());
240 242

  
241 243
		try {
......
343 345

  
344 346
		assertEquals(9, fc.size());
345 347

  
348
		fc.dispose();
349

  
346 350
		try {
347 351
			fc = (IFeatureCollection)fs.getDataCollection(null,"lower(NOMBRE) like 'b%'",null);
348 352
		} catch (ReadException e1) {
......
361 365
		}
362 366
		assertEquals("Iteration error",2,count);
363 367

  
368
		fc.dispose();
364 369

  
370

  
365 371
		try {
366 372
			fc = (IFeatureCollection)fs.getDataCollection(null,null,"NOMBRE ASC");
367 373
		} catch (ReadException e1) {
......
383 389
		}
384 390
		assertEquals("Iteration error",9,count);
385 391

  
392
		fc.dispose();
386 393

  
394

  
387 395
		try {
388 396
			fc = (IFeatureCollection)fs.getDataCollection(null,null,"NOMBRE DESC");
389 397
		} catch (ReadException e1) {
......
406 414
		}
407 415
		assertEquals("Iteration error",9,count);
408 416

  
417
		fc.dispose();
409 418

  
419

  
420

  
410 421
		try {
411 422
			fc = (IFeatureCollection)fs.getDataCollection(null,"lower(NOMBRE) like 'b%'","NOMBRE");
412 423
		} catch (ReadException e1) {
......
432 443
			count++;
433 444
		}
434 445
		assertEquals("Iteration error",2,count);
446
		fc.dispose();
435 447

  
436 448

  
437 449

  
......
457 469
			count++;
458 470
		}
459 471
		assertEquals("Iteration error",9,count);
472
		fc.dispose();
460 473

  
461 474

  
462 475

  
......
483 496
		}
484 497

  
485 498
		assertEquals(10, fc.size());
499
		fc.dispose();
486 500

  
487 501
		try {
488 502
			fc = (IFeatureCollection)fs.getDataCollection(null,"lower(NOMBRE) like 'b%'",null);
......
501 515
			count++;
502 516
		}
503 517
		assertEquals("Iteration error",3,count);
518
		fc.dispose();
504 519

  
505 520

  
506 521
		try {
......
523 538
			count++;
524 539
		}
525 540
		assertEquals("Iteration error",10,count);
541
		fc.dispose();
526 542

  
527 543

  
528 544
		try {
......
546 562
			count++;
547 563
		}
548 564
		assertEquals("Iteration error",10,count);
565
		fc.dispose();
549 566

  
550 567

  
551 568
		try {
......
573 590
			count++;
574 591
		}
575 592
		assertEquals("Iteration error",3,count);
593
		fc.dispose();
576 594

  
577 595

  
578 596

  
......
598 616
			count++;
599 617
		}
600 618
		assertEquals("Iteration error",10,count);
619
		fc.dispose();
601 620

  
602 621

  
603 622
		fs.cancelEditing();
......
650 669
			count++;
651 670
		}
652 671
		assertEquals("Iteration error",10,count);
672
		fc.dispose();
653 673

  
654 674

  
655 675

  
......
701 721
			fail();
702 722
		}
703 723
		assertEquals(1, fc.size());
724
		fc.dispose();
704 725

  
705 726

  
706 727
		//Eliminacion
......
720 741
		}
721 742
		assertEquals(1, fc.size());
722 743
		fs.delete((IFeature)fc.iterator().next());
744
		fc.dispose();
723 745
		try {
724 746
			fs.finishEditing();
725 747
		} catch (WriteException e) {
......
737 759
			fail();
738 760
		}
739 761
		assertEquals(9, fc.size());
762
		fc.dispose();
740 763

  
741 764

  
742 765

  
743

  
744 766
		try {
745 767
			fs.close();
746 768
		} catch (CloseException e) {

Also available in: Unified diff