public void CanSafelyCallDisposeMultipleTimes()
 {
     using (var snapshotStore = new SqlSagaStore(new SqlSagaStoreDialect(SqlServerConnection.Name), new BinarySerializer(), new Mock <ILocateTypes>().Object))
     {
         snapshotStore.Dispose();
         snapshotStore.Dispose();
     }
 }
 public void CanSafelyCallDisposeMultipleTimes()
 {
     using (var snapshotStore = new SqlSagaStore(new SqlSagaStoreDialect(SqlServerConnection.Name), new BinarySerializer(), new Mock<ILocateTypes>().Object))
     {
         snapshotStore.Dispose();
         snapshotStore.Dispose();
     }
 }
            public void ThrowKeyNotFoundIfSagaTypeUnknown()
            {
                var sagaStore = new SqlSagaStore(new SqlSagaStoreDialect(SqlServerConnection.Name), new BinarySerializer(), new Mock<ILocateTypes>().Object);

                Assert.Throws<KeyNotFoundException>(() => sagaStore.CreateSaga(typeof(FakeSaga), GuidStrategy.NewGuid()));
            }
            public void ThrowKeyNotFoundIfSagaTypeUnknown()
            {
                var sagaStore = new SqlSagaStore(new SqlSagaStoreDialect(SqlServerConnection.Name), new BinarySerializer(), new Mock <ILocateTypes>().Object);

                Assert.Throws <KeyNotFoundException>(() => sagaStore.CreateSaga(typeof(FakeSaga), GuidStrategy.NewGuid()));
            }