Program: 141526
Project: 141526
Buggy source:
@Test public void graphChangesShouldAppearInTheChangeFeed() throws InterruptedException {
  registerSingleModuleAndCreateReader();
  performModifications();
  Thread.sleep(1000);
  verifyChanges(3,new GraphChangeReader(getDatabase()).getAllChanges());
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getAllChanges());
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getAllChanges());
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getAllChanges());
  verifyChanges(3,new GraphChangeReader(getDatabase()).getNumberOfChanges(3));
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getNumberOfChanges(3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(3));
  verifyChanges(2,new GraphChangeReader(getDatabase()).getNumberOfChanges(2));
  verifyChanges(2,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase()).getNumberOfChanges(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(2));
  verifyChanges(3,new GraphChangeReader(getDatabase()).getChangesSince(0));
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(0));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getChangesSince(0));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(0));
  verifyChanges(2,new GraphChangeReader(getDatabase()).getChangesSince(2));
  verifyChanges(2,new GraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase()).getChangesSince(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(2));
  verifyChanges(3,new GraphChangeReader(getDatabase()).getNumberOfChangesSince(0,3));
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(0,3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getNumberOfChangesSince(0,3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(0,3));
  verifyChanges(1,new GraphChangeReader(getDatabase()).getNumberOfChangesSince(2,1));
  verifyChanges(1,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(3,3));
  verifyChanges(1,new CachingGraphChangeReader(getDatabase()).getNumberOfChangesSince(3,3));
  verifyChanges(1,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(2,1));
}

Fixed version (ground truth):
@Test public void graphChangesShouldAppearInTheChangeFeed() throws InterruptedException {
  registerSingleModuleAndStart();
  performModifications();
  Thread.sleep(1000);
  verifyChanges(3,new GraphChangeReader(getDatabase()).getAllChanges());
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getAllChanges());
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getAllChanges());
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getAllChanges());
  verifyChanges(3,new GraphChangeReader(getDatabase()).getNumberOfChanges(3));
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getNumberOfChanges(3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(3));
  verifyChanges(2,new GraphChangeReader(getDatabase()).getNumberOfChanges(2));
  verifyChanges(2,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase()).getNumberOfChanges(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChanges(2));
  verifyChanges(3,new GraphChangeReader(getDatabase()).getChangesSince(0));
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(0));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getChangesSince(0));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(0));
  verifyChanges(2,new GraphChangeReader(getDatabase()).getChangesSince(2));
  verifyChanges(2,new GraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase()).getChangesSince(2));
  verifyChanges(2,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getChangesSince(2));
  verifyChanges(3,new GraphChangeReader(getDatabase()).getNumberOfChangesSince(0,3));
  verifyChanges(3,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(0,3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase()).getNumberOfChangesSince(0,3));
  verifyChanges(3,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(0,3));
  verifyChanges(1,new GraphChangeReader(getDatabase()).getNumberOfChangesSince(2,1));
  verifyChanges(1,new GraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(3,3));
  verifyChanges(1,new CachingGraphChangeReader(getDatabase()).getNumberOfChangesSince(3,3));
  verifyChanges(1,new CachingGraphChangeReader(getDatabase(),"String_Node_Str").getNumberOfChangesSince(2,1));
}