private void checkSeveralVersionsOfSameItem(ManageableRepository repository) throws Exception
{
try
{
TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
NodeImpl node1 = (NodeImpl)addTestNode(repository);
NodeImpl node2 = (NodeImpl)addTestNode(repository);
PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node1);
assertResult(checkController.checkDataBase(), checkController.getLastReportPath(), true);
//assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
updateNodeRecord(repository, node2.getInternalIdentifier(), 1, 1);
assertResult(checkController.checkDataBase(), checkController.getLastReportPath(), true);
insertPropertyRecord(repository, prop.getInternalIdentifier(), prop.getParentIdentifier(), prop.getName());
assertResult(checkController.checkDataBase(), checkController.getLastReportPath(), false);
//assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
checkController.repairDataBase("yes");
assertResult(checkController.checkDataBase(), checkController.getLastReportPath(), true);
//assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
}
finally
{
if (repository != null)