### Question:
HtmlLanguageBuilder { public HtmlLanguageBuilder addHeadings(int level) { checkArgument(level > 0 && level <= 6, "Heading level must be between 1 and 6"); headingLevel = level; return this; } HtmlLanguageBuilder(); HtmlLanguageBuilder name(String name); HtmlLanguageBuilder add(BlockType blockType); HtmlLanguageBuilder add(SpanType spanType); HtmlLanguageBuilder addSubstitution(SpanType spanType, String alternativeTagName); HtmlLanguageBuilder addHeadings(int level); HtmlLanguageBuilder addSpanFont(); HtmlLanguageBuilder setXhtmlStrict(boolean xhtmlStrict); HtmlLanguageBuilder document(String prefix, String suffix); HtmlLanguage create();  }### Answer:
@Test public void addHeadings() { assertNotNull(builder.addHeadings(1)); assertSame(builder, builder.addHeadings(1)); }
@Test public void addHeadingsLowerBounds() { builder.addHeadings(1); thrown.expect(IllegalArgumentException.class); thrown.expectMessage("Heading level must be between 1 and 6"); builder.addHeadings(0); }
@Test public void addHeadingsUpperBounds() { builder.addHeadings(6); thrown.expect(IllegalArgumentException.class); thrown.expectMessage("Heading level must be between 1 and 6"); builder.addHeadings(7); }