public async Task Get_WhenCalled_For_ArchetypeSearches_Should_Return_OkResult() { // Arrange var searchCriteria = new ArchetypeSearchQuery(); _mediator.Send(Arg.Any <IRequest <ArchetypeSearchResultOutputModel> >()).Returns(new ArchetypeSearchResultOutputModel()); // Act var result = await _sut.Get(searchCriteria); // Assert result.Should().BeOfType <OkObjectResult>(); }
public async Task <IActionResult> Get([FromQuery] ArchetypeSearchQuery query) { var result = await _mediator.Send(query); return(Ok(result)); }