@Test
  void distinctAndCount() {
    check(generate(Query.of(Person.class).withDistinct(true).withCount(true)))
            .is("SELECT COUNT(*) FROM (SELECT DISTINCT * FROM /myRegion)");

    check(generate(Query.of(Person.class).withDistinct(true).withCount(true)
            .addProjections(toExpression(person.fullName))))
            .is("SELECT COUNT(*) FROM (SELECT DISTINCT fullName FROM /myRegion)");
  }
Check generated OQL out of {@link Query}
criteria/geode/test/org/immutables/criteria/geode/OqlGeneratorTest.java