From 0e62f59bf6ce02323373914b63d95f220683b251 Mon Sep 17 00:00:00 2001 From: Max Schiller Date: Mon, 2 Sep 2024 10:41:06 +0200 Subject: [PATCH] fixed test error for invalid cron config (add mandatory setters) Signed-off-by: Max Schiller --- .../resources/v1/ScheduledNotificationRuleResourceTest.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/test/java/org/dependencytrack/resources/v1/ScheduledNotificationRuleResourceTest.java b/src/test/java/org/dependencytrack/resources/v1/ScheduledNotificationRuleResourceTest.java index 77322cca10..afdaa3362d 100644 --- a/src/test/java/org/dependencytrack/resources/v1/ScheduledNotificationRuleResourceTest.java +++ b/src/test/java/org/dependencytrack/resources/v1/ScheduledNotificationRuleResourceTest.java @@ -187,6 +187,9 @@ public void createScheduledNotificationRuleWithInvalidCronConfigTest() { NotificationPublisher publisher = new NotificationPublisher(); publisher.setUuid(UUID.randomUUID()); ScheduledNotificationRule rule = new ScheduledNotificationRule(); + rule.setName("Example Rule"); + rule.setScope(NotificationScope.PORTFOLIO); + rule.setEnabled(true); rule.setCronConfig("A B C D E"); rule.setLastExecutionTime(ZonedDateTime.now()); Response response = jersey.target(V1_SCHEDULED_NOTIFICATION_RULE).request()