public static boolean toBoolean(final Literal literal, final String propertyName) {
    final String value = literal.getValue().toString();
    final boolean isTrue = value.equalsIgnoreCase("true");
    final boolean isFalse = value.equalsIgnoreCase("false");
    if (!isTrue && !isFalse) {
      throw new KsqlException("Property '" + propertyName + "' is not a boolean value");
    }
    return isTrue;
  }
@Test
  public void shouldConvertBooleanToBoolean() {
    assertThat(LiteralUtil.toBoolean(new BooleanLiteral("true"), "bob"), is(true));
    assertThat(LiteralUtil.toBoolean(new BooleanLiteral("false"), "bob"), is(false));
  }