public void TearDown()
 {
     _bus = null;
     _manager = null;
     _correlationID = Guid.Empty;
     _prepareAck = null;
     _commitAck = null;
 }
 public void SetUp()
 {
     _bus = new FakePublisher();
     _manager = new TwoPhaseCommitRequestManager(_bus, 2, 2);
     _correlationID = Guid.NewGuid();
     _manager.Handle(new ReplicationMessage.WriteRequestCreated(_correlationID,
                                                                new NoopEnvelope(),
                                                                "test-stream",
                                                                -1,
                                                                new Event[0]));
     _prepareAck = new ReplicationMessage.PrepareAck(_correlationID, 0, PrepareFlags.TransactionBegin | PrepareFlags.TransactionEnd);
     _commitAck = new ReplicationMessage.CommitAck(_correlationID, 0, 0);
 }