Class ShouldBeSimilar

java.lang.Object
org.xmlunit.assertj.error.ShouldBeSimilar
All Implemented Interfaces:
org.assertj.core.error.AssertionErrorFactory

public class ShouldBeSimilar extends Object
Since:
XMLUnit 2.6.1
  • Method Details

    • shouldBeIdentical

      public static ShouldBeSimilar shouldBeIdentical(String controlSystemId, String testSystemId, Comparison comparison, ComparisonFormatter formatter, boolean formatXml)
      Parameters:
      controlSystemId - optional systemId of control document
      testSystemId - optional systemId of test document
      comparison - the comparison that failed
      formatter - formatter to use
      formatXml - whether to format the difference as XML
      Returns:
      ErrorMessageFactory when documents are not identical
    • shouldBeSimilar

      public static ShouldBeSimilar shouldBeSimilar(String controlSystemId, String testSystemId, Comparison comparison, ComparisonFormatter formatter, boolean formatXml)
      Parameters:
      controlSystemId - optional systemId of control document
      testSystemId - optional systemId of test document
      comparison - the comparison that failed
      formatter - formatter to use
      formatXml - whether to format the difference as XML
      Returns:
      ErrorMessageFactory when documents are not similar
    • newAssertionError

      public AssertionError newAssertionError(org.assertj.core.description.Description d, org.assertj.core.presentation.Representation representation)
      Create
      org.junit.ComparisonFailure
      if possible.
      Specified by:
      newAssertionError in interface org.assertj.core.error.AssertionErrorFactory