added event driven simulation, added tests for it
Merge remote-tracking branch 'origin/master'