### Question:
QueryException extends RuntimeException implements L10NMessage { @Override public String getMessage() { return message; } QueryException(QueryErrorCode errorCode, Throwable cause, String... arguments);  QueryException(QueryErrorCode errorCode, String... arguments); @Override String getL10NMessage(Locale locale); @Override String getResourceBundleName(); @Override String getErrorCode(); @Override Object[] getMessageArgs(); @Override String getMessage(); @Override String getLocalizedMessage();  }### Answer:
@Test public void shouldMapScriptErrorCodeToMessage() { QueryException qe; qe = new QueryException(FILTER_BOOLEAN_LITERAL_FALSE); assertThat(qe.getMessage()).isEqualTo("The 'boolean literal' filter with value of 'false' is not supported"); qe = new QueryException(FILTER_EXTENDED_MATCH); assertThat(qe.getMessage()).isEqualTo("The 'extended match' filter is not supported"); qe = new QueryException(FILTER_GREATER_THAN); assertThat(qe.getMessage()).isEqualTo("The 'greater than' filter is not supported"); qe = new QueryException(FILTER_GREATER_THAN_OR_EQUAL); assertThat(qe.getMessage()).isEqualTo("The 'greater than or equal' filter is not supported"); qe = new QueryException(FILTER_LESS_THAN); assertThat(qe.getMessage()).isEqualTo("The 'less than' filter is not supported"); qe = new QueryException(FILTER_LESS_THAN_OR_EQUAL); assertThat(qe.getMessage()).isEqualTo("The 'less than or equal' filter is not supported"); qe = new QueryException(FILTER_NOT); assertThat(qe.getMessage()).isEqualTo("The 'not' filter is not supported"); qe = new QueryException(FILTER_PRESENT); assertThat(qe.getMessage()).isEqualTo("The 'present' filter is not supported"); qe = new QueryException(FILTER_DEPTH_NOT_SUPPORTED); assertThat(qe.getMessage()).isEqualTo("Filter path is too long, a depth of 1 is supported"); }