Exemplo n.º 1
0
        public async Task Writer_is_disposed_when_engine_is_disposed()
        {
            await _engine.DisposeAsync().ConfigureAwait(false);

            A.CallTo(() => _fakeJournalWriter.DisposeAsync())
            .MustHaveHappened(Repeated.Exactly.Once);
        }
Exemplo n.º 2
0
        public async Task DisposeAsync()
        {
            _logger.LogDebug("Begin Dispose");
            await _journalWriter.DisposeAsync().ConfigureAwait(false);

            while (!_pendingLocalCommands.IsEmpty)
            {
                _pendingCommandsChanged.WaitOne();
            }

            _commandSubscription.Dispose();
            _logger.LogDebug("End Dispose");
        }