Пример #1
0
            public void ShouldEnqueueRollbackAndSync()
            {
                var mockConn = new Mock <IConnection>();

                BoltV3.RollbackTransactionAsync(mockConn.Object);

                mockConn.Verify(x => x.Enqueue(Rollback, It.IsAny <BookmarkCollector>(), null), Times.Once);
                mockConn.Verify(x => x.SyncAsync(), Times.Once);
            }
            public async Task ShouldEnqueueRollbackAndSync()
            {
                var mockConn = NewConnectionWithMode();

                await BoltV3.RollbackTransactionAsync(mockConn.Object);

                mockConn.Verify(
                    x => x.EnqueueAsync(RollbackMessage.Rollback, It.IsAny <V1.RollbackResponseHandler>(), null, null),
                    Times.Once);
                mockConn.Verify(x => x.SyncAsync(), Times.Once);
            }