MessagesPanelTag extends RequestContextAwareTag { public void setPanelClassName(String panelClassName) { this.panelClassName = panelClassName; }  void setMessagesAttributeName(String messagesAttributeName); void setPanelClassName(String panelClassName); void setPanelTypeClassPrefix(String panelTypeClassPrefix); void setPanelElement(String panelElement); void setOuterElement(String outerElement); void setInnerElement(String innerElement); void setMessagesType(String messagesType); void setDisableHtmlEscape(
            String disableHtmlEscape);  }
@Test public void test13() throws Exception { request.setAttribute(ResultMessages.DEFAULT_MESSAGES_ATTRIBUTE_NAME, Arrays.asList("foo", "bar")); tag.setPanelClassName(""); int ret = tag.doStartTag(); String expected = "<div><ul><li>foo</li><li>bar</li></ul></div>"; assertThat(getOutput(), is(expected)); assertThat(ret, is(TagSupport.EVAL_BODY_INCLUDE)); }
@Test public void test14() throws Exception { request.setAttribute(ResultMessages.DEFAULT_MESSAGES_ATTRIBUTE_NAME, ResultMessages.info().add(ResultMessage.fromText("foo")).add( ResultMessage.fromText("bar"))); tag.setPanelClassName(""); int ret = tag.doStartTag(); String expected = "<div class=\"alert-info\"><ul><li>foo</li><li>bar</li></ul></div>"; assertThat(getOutput(), is(expected)); assertThat(ret, is(TagSupport.EVAL_BODY_INCLUDE)); }
@Test public void test18() throws Exception { request.setAttribute(ResultMessages.DEFAULT_MESSAGES_ATTRIBUTE_NAME, Arrays.asList("foo", null)); tag.setPanelClassName(""); int ret = tag.doStartTag(); String expected = "<div><ul><li>foo</li></ul></div>"; assertThat(getOutput(), is(expected)); assertThat(ret, is(TagSupport.EVAL_BODY_INCLUDE)); }
@Test public void test20() throws Exception { request.setAttribute(ResultMessages.DEFAULT_MESSAGES_ATTRIBUTE_NAME, new int[] { 1, 2 }); tag.setPanelClassName(""); int ret = tag.doStartTag(); String expected = "<div><ul><li>1</li><li>2</li></ul></div>"; assertThat(getOutput(), is(expected)); assertThat(ret, is(TagSupport.EVAL_BODY_INCLUDE)); }