@Test
  protected void whitespace() {
    repository.insert(generator.get().withValue(""));
    repository.insert(generator.get().withValue(" "));
    repository.insert(generator.get().withValue("\n"));

    values(string.value.is("")).hasContentInAnyOrder("");
    values(string.value.is(" ")).hasContentInAnyOrder(" ");
    values(string.value.is("\n")).hasContentInAnyOrder("\n");
    values(string.value.isNot("")).hasContentInAnyOrder(" ", "\n");
    values(string.value.isNot(" ")).hasContentInAnyOrder("", "\n");
    values(string.value.isNot("\n")).hasContentInAnyOrder(" ", "");
  }
Testing various string operations prefix/suffix/length etc.
criteria/common/test/org/immutables/criteria/typemodel/StringTemplate.java