Browse Source

Polishing (backported from 3.2.x)

pull/423/head
Juergen Hoeller 12 years ago
parent
commit
f5a310ad57
  1. 5
      spring-test/src/main/java/org/springframework/test/util/XmlExpectationsHelper.java

5
spring-test/src/main/java/org/springframework/test/util/XmlExpectationsHelper.java

@ -40,7 +40,6 @@ import static org.springframework.test.util.MatcherAssertionErrors.*; @@ -40,7 +40,6 @@ import static org.springframework.test.util.MatcherAssertionErrors.*;
*/
public class XmlExpectationsHelper {
/**
* Parse the content as {@link Node} and apply a {@link Matcher}.
*/
@ -54,8 +53,7 @@ public class XmlExpectationsHelper { @@ -54,8 +53,7 @@ public class XmlExpectationsHelper {
factory.setNamespaceAware(true);
DocumentBuilder documentBuilder = factory.newDocumentBuilder();
InputSource inputSource = new InputSource(new StringReader(xml));
Document document = documentBuilder.parse(inputSource);
return document;
return documentBuilder.parse(inputSource);
}
/**
@ -79,7 +77,6 @@ public class XmlExpectationsHelper { @@ -79,7 +77,6 @@ public class XmlExpectationsHelper {
* @see org.springframework.test.web.servlet.result.MockMvcResultMatchers#xpath(String, Map, Object...)
*/
public void assertXmlEqual(String expected, String actual) throws Exception {
XMLUnit.setIgnoreWhitespace(true);
XMLUnit.setIgnoreComments(true);
XMLUnit.setIgnoreAttributeOrder(true);

Loading…
Cancel
Save