Package org.assertj.core.error
Class ShouldHaveSameContent
java.lang.Object
org.assertj.core.error.BasicErrorMessageFactory
org.assertj.core.error.AbstractShouldHaveTextContent
org.assertj.core.error.ShouldHaveSameContent
- All Implemented Interfaces:
ErrorMessageFactory
Creates an error message indicating that an assertion that verifies that two files/inputStreams/paths have same content failed.
- Author:
- Yvonne Wang, Matthieu Baechler, Joel Costigliola
-
Field Summary
Fields inherited from class org.assertj.core.error.AbstractShouldHaveTextContent
diffs
Fields inherited from class org.assertj.core.error.BasicErrorMessageFactory
arguments, format
-
Method Summary
Modifier and TypeMethodDescriptionstatic ErrorMessageFactory
Creates a new
.ShouldHaveSameContent
static ErrorMessageFactory
shouldHaveSameContent
(InputStream actual, InputStream expected, List<Delta<String>> diffs) Creates a new
.ShouldHaveSameContent
static ErrorMessageFactory
shouldHaveSameContent
(InputStream actual, String expected, List<Delta<String>> diffs) Creates a new
.ShouldHaveSameContent
static ErrorMessageFactory
Creates a new
.ShouldHaveSameContent
Methods inherited from class org.assertj.core.error.AbstractShouldHaveTextContent
create, diffsAsString
Methods inherited from class org.assertj.core.error.BasicErrorMessageFactory
create, create, equals, hashCode, toString, unquotedString
-
Method Details
-
shouldHaveSameContent
public static ErrorMessageFactory shouldHaveSameContent(File actual, File expected, List<Delta<String>> diffs) Creates a new
.ShouldHaveSameContent
- Parameters:
actual
- the actual file in the failed assertion.expected
- the expected file in the failed assertion.diffs
- the differences betweenactual
andexpected
.- Returns:
- the created
ErrorMessageFactory
.
-
shouldHaveSameContent
public static ErrorMessageFactory shouldHaveSameContent(InputStream actual, InputStream expected, List<Delta<String>> diffs) Creates a new
.ShouldHaveSameContent
- Parameters:
actual
- the actual InputStream in the failed assertion.expected
- the expected InputStream in the failed assertion.diffs
- the differences betweenactual
andexpected
.- Returns:
- the created
ErrorMessageFactory
.
-
shouldHaveSameContent
public static ErrorMessageFactory shouldHaveSameContent(InputStream actual, String expected, List<Delta<String>> diffs) Creates a new
.ShouldHaveSameContent
- Parameters:
actual
- the actual InputStream in the failed assertion.expected
- the expected String in the failed assertion.diffs
- the differences betweenactual
andexpected
.- Returns:
- the created
ErrorMessageFactory
.
-
shouldHaveSameContent
public static ErrorMessageFactory shouldHaveSameContent(Path actual, Path expected, List<Delta<String>> diffs) Creates a new
.ShouldHaveSameContent
- Parameters:
actual
- the actual Path in the failed assertion.expected
- the expected Path in the failed assertion.diffs
- the differences betweenactual
andexpected
.- Returns:
- the created
ErrorMessageFactory
.
-