@Test
public void testCleanUpGeneratedEntryIds() throws Exception {

	// Arrange
	initDocumentRedactorWithActualServices();
	final String c32WithGeneratedEntryIds = fileReader
			.readFile("testC32WithGeneratedEntryIds.xml");
	// Act
	final String cleanC32 = documentRedactor
			.cleanUpGeneratedEntryIds(c32WithGeneratedEntryIds);
	// Assert
	final Document docWithGeneratedEntryIds = documentXmlConverter
			.loadDocument(c32WithGeneratedEntryIds);
	final Document docCleanedUp = documentXmlConverter
			.loadDocument(cleanC32);
	final String xPathExpr = "//hl7:generatedEntryId";
	NodeList foundGeneratedEntryIds = documentAccessor.getNodeList(
			docWithGeneratedEntryIds, xPathExpr);
	// original document must have entry ids
	assertTrue(foundGeneratedEntryIds.getLength() > 0);
	foundGeneratedEntryIds = documentAccessor.getNodeList(docCleanedUp,
			xPathExpr);
	// clean document shouldn't have any entry id elements
	assertTrue(foundGeneratedEntryIds.getLength() == 0);
}