added ParameterizedTest for offer validator
This commit is contained in:
@@ -28,6 +28,9 @@ public final class OfferValidator {
|
||||
if (offer.getOfferId().equals("")) {
|
||||
throw new InvalidOfferException("Offer ID cannot be empty");
|
||||
}
|
||||
if (offer.getLastUpdate().equals("")) {
|
||||
throw new InvalidOfferException("LastUpdate cannot be empty");
|
||||
}
|
||||
} catch (NullPointerException e) {
|
||||
throw new InvalidOfferException("Required information is missing in the offer", e);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user