예제 #1
0
  @Test
  public void testParameterForwarding() {
    assertSelection(Sel.not(Sel.filter("col", "a", "b")), "not (col in (?,?))", "a", "b");

    assertSelection(
        Sel.and(constant(42), Sel.filter("col", "1", "2")), "(42) and (col in (?,?))", "1", "2");

    assertSelection(
        Sel.or(Sel.filter("colA", "a"), Sel.filter("colB", "b")),
        "(colA = ?) or (colB = ?)",
        "a",
        "b");
  }
예제 #2
0
 @Test
 public void testConjunction() {
   assertSelection(Sel.and(constant(0), constant(1)), "(0) and (1)");
 }