code: public static void assertXpathEvaluatesTo(String expectedValue,
                                                String xpathExpression,
                                                Document inDocument)
          throws XpathException {
          XpathEngine simpleXpathEngine = XMLUnit.newXpathEngine();
          assertEquals(expectedValue,
                       simpleXpathEngine.evaluate(xpathExpression, inDocument));
      }
docs: Assert the value of an Xpath expression in an DOM Document
  @param expectedValue
  @param xpathExpression
  @param inDocument
  @see XpathEngine which provides the underlying evaluation mechanism