From: <one...@us...> - 2003-01-12 14:45:41
|
Update of /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/test In directory sc8-pr-cvs1:/tmp/cvs-serv21630/src/net/sf/hibernate/test Modified Files: FooBarTest.java ParentChildTest.java Log Message: tests Index: FooBarTest.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/test/FooBarTest.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** FooBarTest.java 12 Jan 2003 14:22:10 -0000 1.7 --- FooBarTest.java 12 Jan 2003 14:45:38 -0000 1.8 *************** *** 165,169 **** while ( iter.hasNext() ) { Object[] arr = (Object[]) iter.next(); System.out.println( arr[0] + " " + arr[1] + " " + arr[2] + " " + arr[3] ); } ! assertTrue( s.iterate("select max(baz.timeArray.elements) from baz in class Baz where baz.id=?", baz.getCode(), Hibernate.STRING).next() instanceof Time ); assertTrue( s.iterate("select max(baz.stringSet.elements) from baz in class Baz where baz.id=?", baz.getCode(), Hibernate.STRING).next().equals("foo") ); assertTrue( s.iterate("select size(baz.stringSet) from baz in class Baz where baz.id=?", baz.getCode(), Hibernate.STRING).next().equals( new Integer(3) ) ); --- 165,169 ---- while ( iter.hasNext() ) { Object[] arr = (Object[]) iter.next(); System.out.println( arr[0] + " " + arr[1] + " " + arr[2] + " " + arr[3] ); } ! assertTrue( s.iterate("select max( elements(baz.timeArray) ) from baz in class Baz where baz.id=?", baz.getCode(), Hibernate.STRING).next() instanceof Time ); assertTrue( s.iterate("select max(baz.stringSet.elements) from baz in class Baz where baz.id=?", baz.getCode(), Hibernate.STRING).next().equals("foo") ); assertTrue( s.iterate("select size(baz.stringSet) from baz in class Baz where baz.id=?", baz.getCode(), Hibernate.STRING).next().equals( new Integer(3) ) ); Index: ParentChildTest.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/test/ParentChildTest.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** ParentChildTest.java 5 Jan 2003 02:11:23 -0000 1.3 --- ParentChildTest.java 12 Jan 2003 14:45:38 -0000 1.4 *************** *** 46,556 **** assertTrue( s.find("select c from c in class Container, s in class Simple where c.oneToMany[2] = s") ! .size() == 1 ); assertTrue( ! s.find("select c from c in class Container, s in class Simple where c.manyToMany[2] = s") ! .size() == 1 ); ! assertTrue( ! s.find("select c from c in class Container, s in class Simple where s = c.oneToMany[2]") ! .size() == 1 ); ! assertTrue( [...1009 lines suppressed...] ! "Immutable.hbm.xml", ! "Fee.hbm.xml", ! "Vetoer.hbm.xml", ! "Holder.hbm.xml", ! "ParentChild.hbm.xml", ! "Simple.hbm.xml", ! "Container.hbm.xml", ! "Circular.hbm.xml", ! "Stuff.hbm.xml" ! } ); ! return new TestSuite(ParentChildTest.class); ! } ! catch (Exception e) { ! e.printStackTrace(); ! throw e; ! } ! } ! } |