### Question:
CndImporter { protected void parse( String content ) { Tokenizer tokenizer = new CndTokenizer(false, false); TokenStream tokens = new TokenStream(content, tokenizer, false); tokens.start(); while (tokens.hasNext()) { if (tokens.matches("<", ANY_VALUE, "=", ANY_VALUE, ">")) { parseNamespaceMapping(tokens); } else if (tokens.matches("[", ANY_VALUE, "]")) { parseNodeTypeDefinition(tokens, outputPath); } else { Position position = tokens.previousPosition(); throw new ParsingException(position, CndI18n.expectedNamespaceOrNodeDefinition.text(tokens.consume(), position.getLine(), position.getColumn())); } } } CndImporter( Destination destination,
                        Path parentPath,
                        boolean compatibleWithPreJcr2 );  CndImporter( Destination destination,
                        Path parentPath ); void importFrom( InputStream stream,
                            Problems problems,
                            String resourceName ); void importFrom( File file,
                            Problems problems ); void importFrom( String content,
                            Problems problems,
                            String resourceName );  }### Answer:
@Test( expected = ParsingException.class ) public void shouldReportErrorIfTheNodeTypeNameIsEmpty() { String cnd = "<ns = 'http: importer.parse(cnd); }
@Test( expected = ParsingException.class ) public void shouldReportErrorIfTheNodeTypeNameIsBlank() { String cnd = "<ns = 'http: importer.parse(cnd); }
@Test( expected = ParsingException.class ) public void shouldReportErrorIfTheNodeTypeNameIsNotFollowedByClosingBracket() { String cnd = "<ns = 'http: importer.parse(cnd); }
@Test( expected = ParsingException.class ) public void shouldReportErrorIfTheNodeTypeNameUsesInvalidNamespace() { String cnd = "<ns = 'http: importer.parse(cnd); }
@Test public void shouldParseNamespaceDeclarationWithQuotedUriAndQuotedPrefix() { String cnd = "<'ns' = 'http: importer.parse(cnd); }
@Test public void shouldParseNamespaceDeclarationWithUnquotedUriAndQuotedPrefix() { String cnd = "<'ns' = http_namespace.com_ns>"; importer.parse(cnd); }
@Test public void shouldParseNamespaceDeclarationWithQuotedUriAndUnquotedPrefix() { String cnd = "<ns = 'http: importer.parse(cnd); }
@Test public void shouldParseNamespaceDeclarationWithUnquotedUriAndUnquotedPrefix() { String cnd = "<ns = http_namespace.com_ns>"; importer.parse(cnd); }
@Test public void shouldParseMinimalNodeDefinition() { String cnd = "[nodeTypeName]"; importer.parse(cnd); }
@Test public void shouldParseMinimalNodeDefinitionWithSupertype() { String cnd = "[nodeTypeName] > supertype"; importer.parse(cnd); }
@Test public void shouldParseMinimalNodeDefinitionWithSupertypes() { String cnd = "[nodeTypeName] > supertype1, supertype2"; importer.parse(cnd); }
@Test public void shouldParseNodeDefinitionWithNameThatIsKeyword() { String cnd = "[abstract] > supertype1, supertype2"; importer.parse(cnd); }