XPath xpathEmail = XPath.newInstance("//contacts/contact/email");
Element nomElement = (Element) xpathNom.selectSingleNode(document);
Element prenomElement = (Element) xpathPrenom.selectSingleNode(document);
Element emailElement = (Element) xpathEmail.selectSingleNode(document);
assertEquals("nom", nomElement.getText());
assertEquals("prenom", prenomElement.getText());
assertEquals("hikage@hikage.be", emailElement.getText());
assertEquals("personnelle", emailElement.getAttributeValue("type"));