public void Controller_Get_Should_Be_NoContentResult() { var fixture = new DbContextFixture(); var logger = new Mock <ILogger <ReportRequestsController> >().Object; var repository = new ReportRequestRepository(fixture.context); var controller = new ReportRequestsController(logger, repository); ActionResult <IQueryable <ReportRequest> > result = controller.Get(); result.Result.Should().BeOfType <NoContentResult>(); }
public void Controller_Get_ById_Should_Be_NoContentResult() { var fixture = new DbContextFixture(); var logger = new Mock <ILogger <ReportRequestsController> >().Object; var repository = new ReportRequestRepository(fixture.context); var controller = new ReportRequestsController(logger, repository); var e = ReportRequestEntityTypeConfiguration.ReportRequestSeed.First().Id; ActionResult <ReportRequest> result = controller.Get(e); result.Result.Should().BeOfType <NoContentResult>(); }