### Question:
JcrSqlQueryParser extends SqlQueryParser { @Override protected String parseName( TokenStream tokens, TypeSystem typeSystem ) { String token1 = tokens.consume(); token1 = removeBracketsAndQuotes(token1); if (tokens.canConsume(':')) { String token2 = tokens.consume(); token2 = removeBracketsAndQuotes(token2); return token1 + ':' + token2; } return token1; } JcrSqlQueryParser(); @Override String getLanguage(); @SuppressWarnings( "deprecation" )
    static final String LANGUAGE; }### Answer:
@Test public void shouldParseNonPrefixedNameFromUnquotedString() { assertThat(parser.parseName(tokens("name"), typeSystem), is("name")); }
@Test public void shouldParsePrefixedNameFromUnquotedString() { assertThat(parser.parseName(tokens("jcr:name"), typeSystem), is("jcr:name")); }
@Test public void shouldParseNameFromSingleQuotedString() { assertThat(parser.parseName(tokens("'jcr:name'"), typeSystem), is("jcr:name")); }
@Test public void shouldParseNameFromUnquotedStringWithoutPrefix() { assertThat(parser.parseName(tokens("name"), typeSystem), is("name")); }
@Test public void shouldParseNameFromSingleQuotedStringWithoutPrefix() { assertThat(parser.parseName(tokens("'name'"), typeSystem), is("name")); }
@Test( expected = ParsingException.class ) public void shouldFailToParseNameIfNoMoreTokens() { parser.parseName(tokens(" "), typeSystem); }