public void GetOffer_ConstructsQuery_ReturnsResultOfDispatch() { var offerId = TestIds.A; var offerDto = new OfferDto(); _dispatcherMock.Setup(d => d.QueryAsync(It.Is <GetOffer>(q => q.Id == offerId))).ReturnsAsync(offerDto).Verifiable(); var actionResult = _controller.GetOffer(offerId).GetAwaiter().GetResult(); Assert.AreEqual(offerDto, actionResult.Value); _dispatcherMock.Verify(); }