@Test public void detectsDifferentListElements() { Node actual = Node.fromStrings("fizz", "buzz", "pop"); Node expected = Node.fromStrings("snap", "crackle", "pop"); assertThat(NodeDiff.diff(actual, expected), contains( "[[0]]: Expected `\"snap\"` but found `\"fizz\"`", "[[1]]: Expected `\"crackle\"` but found `\"buzz\"`")); }
static List<String> diff(ToNode actual, ToNode expected) { return new NodeDiff().findDifferences(actual.toNode(), expected.toNode(), "") .collect(Collectors.toList()); }
NodeDiff { static List<String> diff(ToNode actual, ToNode expected) { return new NodeDiff().findDifferences(actual.toNode(), expected.toNode(), "") .collect(Collectors.toList()); } }
NodeDiff { static List<String> diff(ToNode actual, ToNode expected) { return new NodeDiff().findDifferences(actual.toNode(), expected.toNode(), "") .collect(Collectors.toList()); } NodeDiff(); }
NodeDiff { static List<String> diff(ToNode actual, ToNode expected) { return new NodeDiff().findDifferences(actual.toNode(), expected.toNode(), "") .collect(Collectors.toList()); } NodeDiff();  }
NodeDiff { static List<String> diff(ToNode actual, ToNode expected) { return new NodeDiff().findDifferences(actual.toNode(), expected.toNode(), "") .collect(Collectors.toList()); } NodeDiff();   }