@Test
public void with_anchor()
{
Link link = mockLink();
ComponentResources resources = mockComponentResources();
ComponentInvocationMap map = new PageTesterComponentInvocationMap();
MarkupWriter writer = new MarkupWriterImpl();
ComponentInvocation invocation = mockComponentInvocation();
map.store(link, invocation);
train_toURI(link, LINK_URI);
resources.renderInformalParameters(writer);
replay();
_linkFixture.inject("wilma", map, resources);
_linkFixture.writeLink(writer, "barney", link);
verify();
Element e = writer.getElement();
writer.write("link text");
writer.end();
assertEquals(writer.toString(), "<a href=\"/foo/bar.baz#wilma\" id=\"barney\">link text</a>");
assertSame(map.get(e), invocation);
}