### Question:
JAnnotation { public String toString() { StringBuilder sb = new StringBuilder(); sb.append('@'); sb.append(type.getSimpleName()); if (getElements().isEmpty()) { return sb.toString(); } sb.append('('); for (int i = 0; i < elements.size(); i++) { sb.append(elements.get(i)); if (i < elements.size() - 1) { sb.append(", "); } } sb.append(')'); return sb.toString(); } JAnnotation();  JAnnotation(Class<?> t); Set<String> getImports(); List<JAnnotationElement> getElements(); void addElement(JAnnotationElement element); Class<?> getType(); void setType(final Class<?> newType); String toString();  }### Answer:
@Test public void testSimpleForm() { JAnnotation annotation = new JAnnotation(WebService.class); assertEquals("@WebService", annotation.toString()); }