{
@Test
public void shouldDiffThings()
{
final List<String> propertyNames = asList("things", "include");
ObjectDifferBuilder builder = ObjectDifferBuilder.startBuilding();
for (final String name : propertyNames)
{
final NodePath nodePath = NodePath.with(name);
builder.comparison().ofNode(nodePath).toUseEqualsMethod();
builder.inclusion().include().node(nodePath);
}
final Thing thingOne = new Thing("a", "b");
final Thing thingTwo = new Thing("aa", "bb");
final ThingHolder first = new ThingHolder(singleton(thingOne), "ignore", "include");
final ThingHolder second = new ThingHolder(singleton(thingTwo), "ignore this change", "include");
final DiffNode compareResults = builder.build().compare(first, second);
assertThat(compareResults.isChanged(), is(true));
}