@Test
public void testStartEndElement() throws XMLStreamException {

	XMLStreamReader reader = createXmlStreamReader("<alice/>");
	StartElement startElement = eventAllocator.allocate(reader).asStartElement();
	verify(startElement, XMLStreamConstants.START_ELEMENT, "<alice>");
	Assert.assertEquals(new QName("alice"), startElement.getName());
	Assert.assertNotNull(startElement.getNamespaceContext());
	Assert.assertFalse(startElement.getAttributes().hasNext());
	Assert.assertFalse(startElement.getNamespaces().hasNext());
	Assert.assertNull(startElement.getNamespaceURI("foo"));
	reader.next();
	EndElement endElement = eventAllocator.allocate(reader).asEndElement();
	verify(endElement, XMLStreamConstants.END_ELEMENT, "</alice>");
	Assert.assertEquals(new QName("alice"), endElement.getName());
	Assert.assertFalse(endElement.getNamespaces().hasNext());
}