use of org.assertj.core.test.Employee in project assertj-core by joel-costigliola.
the class AtomicReferenceArrayAssert_filtered_baseTest method setUp.
@Before
public void setUp() {
yoda = new Employee(1L, new Name("Yoda"), 800);
obiwan = new Employee(2L, new Name("Obi"), 800);
luke = new Employee(3L, new Name("Luke", "Skywalker"), 26);
noname = new Employee(4L, null, 10);
employees = new AtomicReferenceArray<>(new Employee[] { yoda, luke, obiwan, noname });
}
use of org.assertj.core.test.Employee in project assertj-core by joel-costigliola.
the class AtomicReferenceArrayAssert_extracting_Test method setUpOnce.
@BeforeClass
public static void setUpOnce() {
yoda = new Employee(1L, new Name("Yoda"), 800);
luke = new Employee(2L, new Name("Luke", "Skywalker"), 26);
employees = new AtomicReferenceArray<>(array(yoda, luke));
}
use of org.assertj.core.test.Employee in project assertj-core by joel-costigliola.
the class Objects_assertIsEqualToComparingOnlyGivenFields_Test method should_fail_when_one_of_actual_field_to_compare_can_not_be_found_in_the_other_object.
@Test
public void should_fail_when_one_of_actual_field_to_compare_can_not_be_found_in_the_other_object() {
thrown.expectIntrospectionErrorWithMessageContaining("Can't find any field or property with name 'lightSaberColor'");
Jedi actual = new Jedi("Yoda", "Green");
Employee other = new Employee();
objects.assertIsEqualToComparingOnlyGivenFields(someInfo(), actual, other, noFieldComparators(), defaultTypeComparators(), "lightSaberColor");
}
use of org.assertj.core.test.Employee in project assertj-core by joel-costigliola.
the class Objects_assertIsEqualToIgnoringGivenFields_Test method should_fail_when_one_of_actual_field_to_compare_can_not_be_found_in_the_other_object.
@Test
public void should_fail_when_one_of_actual_field_to_compare_can_not_be_found_in_the_other_object() {
Jedi actual = new Jedi("Yoda", "Green");
Employee other = new Employee();
thrown.expectIntrospectionErrorWithMessageContaining("Can't find any field or property with name 'lightSaberColor'");
objects.assertIsEqualToIgnoringGivenFields(someInfo(), actual, other, noFieldComparators(), defaultTypeComparators(), "name");
}
use of org.assertj.core.test.Employee in project assertj-core by joel-costigliola.
the class Objects_assertIsEqualToIgnoringNullFields_Test method should_fail_when_one_of_actual_field_to_compare_can_not_be_found_in_the_other_object.
@Test
public void should_fail_when_one_of_actual_field_to_compare_can_not_be_found_in_the_other_object() {
thrown.expectIntrospectionErrorWithMessageContaining("Can't find any field or property with name 'lightSaberColor'");
Jedi actual = new Jedi("Yoda", "Green");
Employee other = new Employee();
objects.assertIsEqualToIgnoringNullFields(someInfo(), actual, other, noFieldComparators(), defaultTypeComparators());
}
Aggregations