public static Format of(final FormatInfo formatInfo) {
    final Format format = fromName(formatInfo.getFormat().toUpperCase());
    format.validateProperties(formatInfo.getProperties());
    return format;
  }
@Test
  public void shouldThrowOnUnknownFormat() {
    // When:
    final Exception e = assertThrows(
        KsqlException.class,
        () -> of(FormatInfo.of("bob"))
    );

    // Then:
    assertThat(e.getMessage(), containsString("Unknown format: BOB"));
  }