public async Task CloseAllAsyncTestAsync() { await _dut.CloseAllAsync(); _client1.Verify(c => c.CloseAsync(), Times.Once); _client2.Verify(c => c.CloseAsync(), Times.Once); }
public async Task AllMethodsWorkWithoutFailureOnEmpty() { var emptyClients = new PcsSubscriptionClients(); var handler = new Mock <Func <IPcsSubscriptionClient, Message, CancellationToken, Task> >(); var options = new MessageHandlerOptions(Test); await emptyClients.CloseAllAsync(); emptyClients.RegisterPcsMessageHandler(handler.Object, options); }