/**
* Tests the proposals for ELEMENT.
*/
public void testAutocompleteHtmlElements() {
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, "<a"));
AutocompleteProposals proposals = findAutocompletions();
assertEquals(7, proposals.size());
assertEquals("abbr", proposals.get(1).getName());
lineTokens.clear();
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, "<bod"));
proposals = findAutocompletions();
assertEquals(1, proposals.size());
assertEquals("body", proposals.get(0).getName());
lineTokens.clear();
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, "<body"));
assertEquals(1, findAutocompletions().size());
lineTokens.clear();
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, "<body"));
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, ">"));
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, "</body"));
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, ">"));
assertTrue(findAutocompletions().isEmpty());
lineTokens.clear();
lineTokens.add(new Token(CodeMirror2.HTML, TokenType.TAG, "<"));
assertEquals(
HtmlTagsAndAttributes.getInstance().searchTags("").size(), findAutocompletions().size());
}