diff --git a/notification-manager/src/main/java/de/itvsh/kop/notification/user/UserNotificationService.java b/notification-manager/src/main/java/de/itvsh/kop/notification/user/UserNotificationService.java index f9d8caa4c6041d534236605121518538e853d7cb..88d2070ce6870eeb18ac9dc8055dab8ffb417dcd 100644 --- a/notification-manager/src/main/java/de/itvsh/kop/notification/user/UserNotificationService.java +++ b/notification-manager/src/main/java/de/itvsh/kop/notification/user/UserNotificationService.java @@ -5,7 +5,6 @@ import java.util.List; import javax.validation.constraints.NotNull; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.scheduling.annotation.Async; import org.springframework.stereotype.Service; import org.springframework.validation.annotation.Validated; @@ -25,7 +24,6 @@ public class UserNotificationService { @Autowired private UserRemoteService userRemoteService; - @Async public void sendNotification(@NotNull String organisationEinheitId) { var recipients = userRemoteService.getRecipients(organisationEinheitId); emailRemoteService.sendEmail(buildUserEmail(recipients)); diff --git a/pluto-server/src/test/java/de/itvsh/ozg/pluto/vorgang/UserNotificationITCase.java b/pluto-server/src/test/java/de/itvsh/ozg/pluto/vorgang/UserNotificationITCase.java index 14b8bf9cbdd80ca4efc67ac8c862635685ebf1c6..64ac260fb6c1923c9b08a4425cf6b86bfcc4573d 100644 --- a/pluto-server/src/test/java/de/itvsh/ozg/pluto/vorgang/UserNotificationITCase.java +++ b/pluto-server/src/test/java/de/itvsh/ozg/pluto/vorgang/UserNotificationITCase.java @@ -11,17 +11,15 @@ import org.junit.jupiter.api.Nested; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.mock.mockito.MockBean; -import org.springframework.security.test.context.support.WithMockUser; -import de.itvsh.kop.common.test.DataITCase; +import de.itvsh.kop.common.test.ITCase; import de.itvsh.kop.notification.user.UserNotificationEventListener; import de.itvsh.kop.notification.vorgang.Vorgang; import de.itvsh.kop.notification.vorgang.VorgangId; import de.itvsh.kop.notification.vorgang.VorgangService; import de.itvsh.ozg.pluto.command.VorgangCreatedEvent; -@DataITCase -@WithMockUser +@ITCase public class UserNotificationITCase { @Autowired