public void DbThrowsError_Throws() { var expected = new Exception("DB Error"); _db.Setup(x => x.Users).Throws(expected); Action action = () => _svc.GetContractRate(_db.Object, LOAD_ID, USER_ID); action.Should().Throw <Exception>(expected.Message); }
public void DbThrowsError_Throws() { var expected = new Exception("DB Error"); _db.Setup(x => x.Users).Throws(expected); Action action = () => _svc.GetContractRate(_db.Object, LOAD_ID, USER_ID); action.Should().Throw <Exception>(expected.Message); }