public void DeleteEmployer_AlreadyCanceledEmployer_ShouldReturnBadRequest() { var employer = new Employer(); employer.Disable(); _mockBusiness.Setup(x => x.GetEmployer("1", "2")).Returns(employer); var result = _controller.DeleteEmployer("1", "2"); result.Should().BeOfType <BadRequestResult>(); }
public void GetEmployer_EmployerIsDisabled_ShouldReturnNotFound() { var employer = new Employer { FirstName = "1", LastName = "2" }; employer.Disable(); _mockBusiness.Setup(x => x.GetEmployer("1", "2")).Returns(employer); var result = _controller.GetEmployer("1", "2"); result.Should().BeOfType <NotFoundResult>(); }