@Test
  public void xyzAndAbc() {
    assertExpressional(RootCriteria.root
                    .x.value.isEmpty()
                    .a.value().value.is("a")
            ,
            "call op=AND",
            "  call op=EQUAL path=x.value constant=",
            "  call op=EQUAL path=a.value constant=a"
    );

    assertExpressional(RootCriteria.root
                    .x.value.isEmpty().or()
                    .a.value().value.is("a")
            ,
            "call op=OR",
            "  call op=EQUAL path=x.value constant=",
            "  call op=EQUAL path=a.value constant=a"
    );

    assertExpressional(RootCriteria.root
                    .a.value().value.is("a")
                    .x.value.isEmpty()
            ,
            "call op=AND",
            "  call op=EQUAL path=a.value constant=a",
            "  call op=EQUAL path=x.value constant="
    );
  }
Combination of required and optional fields
criteria/common/test/org/immutables/criteria/nested/NestedTest.java