static boolean toBoolean(final JsonNode object) {
    if (object instanceof BooleanNode) {
      return object.booleanValue();
    }

    throw invalidConversionException(object, SqlBaseType.BOOLEAN);
  }
@Test
  public void shouldConvertToBooleanCorrectly() {
    final Boolean b = JsonSerdeUtils.toBoolean(BooleanNode.TRUE);
    assertThat(b, equalTo(true));
  }