public class ColorFixture extends Object
Colors.| Constructor and Description |
|---|
ColorFixture(Color target)
Creates a new
ColorFixture. |
ColorFixture(Color target,
org.assertj.core.description.Description description)
Creates a new
ColorFixture. |
ColorFixture(Color target,
String description)
Creates a new
ColorFixture. |
| Modifier and Type | Method and Description |
|---|---|
String |
description() |
ColorFixture |
requireEqualTo(Color color)
Verifies that this fixture's
Color is equal to the given one. |
ColorFixture |
requireEqualTo(String hexValue)
Verifies that this fixture's
Color is equal to the given color represented by the given hexadecimal value
(e.g. |
ColorFixture |
requireNotEqualTo(Color color)
Verifies that this fixture's
Color is not equal to the given one. |
ColorFixture |
requireNotEqualTo(String hexValue)
Verifies that this fixture's
Color is not equal to the given color represented by the given hexadecimal
value (e.g. |
Color |
target() |
public ColorFixture(@Nonnull Color target)
ColorFixture.target - the color to manage.NullPointerException - if target is null.public ColorFixture(@Nonnull Color target, @Nonnull String description)
ColorFixture.target - the color to manage.description - this fixture's description.NullPointerException - if target is null.public ColorFixture(@Nonnull Color target, @Nullable org.assertj.core.description.Description description)
ColorFixture.target - the color to manage.description - this fixture's description.NullPointerException - if target is null.@Nonnull public ColorFixture requireEqualTo(@Nonnull String hexValue)
Color is equal to the given color represented by the given hexadecimal value
(e.g. "82A9FF".)hexValue - the value representing the color to compare to.NullPointerException - if the hexadecimal code is null.IllegalArgumentException - if the hexadecimal code is empty.NumberFormatException - if the hexadecimal code is empty.AssertionError - if this fixture's Color is not equal to the given one.@Nonnull public ColorFixture requireEqualTo(@Nullable Color color)
Color is equal to the given one.color - the given Color to compare to.AssertionError - if this fixture's Color is not equal to the given one.@Nonnull public ColorFixture requireNotEqualTo(@Nonnull String hexValue)
Color is not equal to the given color represented by the given hexadecimal
value (e.g. "82A9FF".)hexValue - the value representing the color to compare to.NullPointerException - if the hexadecimal code is null.IllegalArgumentException - if the hexadecimal code is empty.NumberFormatException - if the hexadecimal code is empty.AssertionError - if this fixture's Color is equal to the given one.@Nonnull public ColorFixture requireNotEqualTo(@Nullable Color color)
Color is not equal to the given one.color - the given Color to compare to.AssertionError - if this fixture's Color is equal to the given one.Copyright © 2014 AssertJ. All rights reserved.