public class XmlExpectationsHelper extends Object
| Constructor and Description | 
|---|
XmlExpectationsHelper()  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
assertNode(String content,
          org.hamcrest.Matcher<? super Node> matcher)
Parse the content as  
Node and apply a Matcher. | 
void | 
assertSource(String content,
            org.hamcrest.Matcher<? super Source> matcher)
Parse the content as  
DOMSource and apply a Matcher. | 
void | 
assertXmlEqual(String expected,
              String actual)
Parse the expected and actual content strings as XML and assert that the
 two are "similar" -- i.e. 
 | 
public void assertNode(String content, org.hamcrest.Matcher<? super Node> matcher) throws Exception
Node and apply a Matcher.Exceptionpublic void assertSource(String content, org.hamcrest.Matcher<? super Source> matcher) throws Exception
DOMSource and apply a Matcher.Exceptionpublic void assertXmlEqual(String expected, String actual) throws Exception
Use of this method assumes the XMLUnit library is available.
expected - the expected XML contentactual - the actual XML contentExceptionMockMvcResultMatchers.xpath(String, Object...), 
MockMvcResultMatchers.xpath(String, Map, Object...)