@Test
public void testRemoval() {

	ObjectNode jsonObject = new ObjectNode(JsonNodeFactory.instance);
	jsonObject.put("key", "value");
	jsonObject.put("hello", "world");
	ArrayNode jsonArray = new ArrayNode(JsonNodeFactory.instance);
	jsonArray.add(new TextNode("Hello there"));
	jsonArray.add(new IntNode(42));
	jsonArray.add(jsonObject);
	InvalidDocumentFilter filter = new InvalidDocumentFilter(source, registry);
	ArrayNode jsonResult = filter.doFilter(jsonArray);
	Assert.assertEquals(1, jsonResult.size());
	Assert.assertEquals(jsonResult.get(0), jsonObject);
}