|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fest.assertions.internal.Images
public class Images
Reusable assertions for s.
BufferedImage
| Method Summary | |
|---|---|
void |
assertEqual(AssertionInfo info,
BufferedImage actual,
BufferedImage expected)
Asserts that two images are equal. |
void |
assertEqual(AssertionInfo info,
BufferedImage actual,
BufferedImage expected,
Offset<Integer> offset)
Asserts that two images are equal. |
void |
assertHasSize(AssertionInfo info,
BufferedImage actual,
Dimension size)
Asserts that the size of the given image is equal to the given size. |
void |
assertNotEqual(AssertionInfo info,
BufferedImage actual,
BufferedImage other)
Asserts that two images are not equal. |
static Images |
instance()
Returns the singleton instance of this class. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static Images instance()
public void assertEqual(AssertionInfo info,
BufferedImage actual,
BufferedImage expected)
info - contains information about the assertion.actual - the actual image.expected - the expected image.
AssertionError - if the actual image is not equal to the expected one.
public void assertEqual(AssertionInfo info,
BufferedImage actual,
BufferedImage expected,
Offset<Integer> offset)
info - contains information about the assertion.actual - the actual image.expected - the expected image.offset - helps decide if the color of two pixels are similar: two pixels that are identical to the human eye may still
have slightly different color values. For example, by using an offset of 1 we can indicate that a blue value of 60
is similar to a blue value of 61.
NullPointerException - if the given offset is null.
AssertionError - if the actual image is not equal to the expected one.
public void assertNotEqual(AssertionInfo info,
BufferedImage actual,
BufferedImage other)
info - contains information about the assertion.actual - the given image.other - the object to compare actual to.
AssertionError - if actual is equal to other.
public void assertHasSize(AssertionInfo info,
BufferedImage actual,
Dimension size)
info - contains information about the assertion.actual - the given image.size - the expected size of actual.
NullPointerException - if the given size is null.
AssertionError - if the size of the given image is not equal to the given size.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||