@Test
public void attributeToEnum() throws IllegalArgumentException, SecurityException, InstantiationException,
		IllegalAccessException, InvocationTargetException, NoSuchMethodException, ClassNotFoundException {

	nu.xom.Element eAttr = new nu.xom.Element("attribute", SpecificationWriter.NS);
	eAttr.addAttribute(new nu.xom.Attribute("name", "test"));
	eAttr.addAttribute(new nu.xom.Attribute("type", E1.class.getName()));
	eAttr.appendChild(E1.a.name());
	System.out.println(eAttr.toXML());
	SpecificationReader reader = new SpecificationReader();
	E1 e = (E1) reader.toAttribute(eAttr);
	Assert.assertEquals(E1.a, e);
	Assert.assertNotEquals(E1.b, e);
}