added test

This commit is contained in:
Timo Westkämper 2011-11-28 22:39:57 +02:00
parent d73281d48a
commit d808fb6c27
3 changed files with 11 additions and 0 deletions

Binary file not shown.

View File

@ -66,6 +66,10 @@ extends RichProjectable(qry) {
select(f1(path), f2(path), f3(path), f4(path), f5(path))
}
def selectGrouped[K,T,V](fkey: FEx[K], fparent: FEx[T], fchild: FEx[V]): List[(T,Set[V])] = {
selectGrouped(fkey(path), fparent(path), fchild(path))
}
def single: Option[T] = single(expr)
def single[T](f: FEx[T]): Option[T] = single(f(path))

View File

@ -162,6 +162,13 @@ class JDBCIntegrationTest extends CompileTestUtils with SQLHelpers {
assertEquals(2, employee.query.count)
}
@Test
@Ignore
def Join {
val sup = Employee as "sup"
val result: List[(Employee, Employee)] = employee.join(_.superiorFk, sup).select
}
@Test
def Unique_Result {
assertEquals("abc", query.from(survey).where(survey.id eq 1).uniqueResult(survey.name))