ViewHelper { public String memberText(GroupDocumentation g, GroupMember m) { StringBuffer sb = new StringBuffer(m.getId()); if(!m.isSizeIndicator()) { sb.append("1 to " + g.getMax()); } return sb.toString(); }  String sectionHeaderText(int section, int subsection, FunctionDocumentation functionDocumentation); String sectionAnchor(int section, int subsection); String sectionNumber(int section, int subsection); String href(String id); String href(ItemDocumentation itemDocumentation); String href(ItemDocumentationSupport ids); String itemAnchor(ItemDocumentation itemDocumentation); String memberText(GroupDocumentation g, GroupMember m); String summarize(BaseDocumentation doc, int length, String elideText);  }
@Test public void testMemberText() { GroupMember member = new GroupMember(); member.setId("gMember"); member.setSizeIndicator(true); assertEquals("gMember", vh.memberText(null, member)); member.setSizeIndicator(false); GroupDocumentation group = new GroupDocumentation(); group.setMax(12); assertEquals("gMember1 to 12", vh.memberText(group, member)); }