From e58d9fe4e1dbea3556f40aee827c403a57fa3366 Mon Sep 17 00:00:00 2001 From: Hassan Matout Date: Mon, 25 Nov 2024 20:41:25 +0100 Subject: [PATCH] Development: Fix failing server tests due to public testing classes and illegal annotation --- .../notifications/service/mail/ActivationMailTest.java | 2 +- .../notifications/service/mail/DataExportFailedMailTest.java | 2 +- .../service/mail/DataExportSuccessfulMailTest.java | 4 +--- .../notifications/service/mail/PasswordResetMailTest.java | 2 +- .../notifications/service/mail/SAML2SetPasswordMailTest.java | 2 +- .../notifications/service/mail/WeeklySummaryMailTest.java | 2 +- 6 files changed, 6 insertions(+), 8 deletions(-) diff --git a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/ActivationMailTest.java b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/ActivationMailTest.java index 16ed44b4c2b6..b4dfe2c65e5b 100644 --- a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/ActivationMailTest.java +++ b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/ActivationMailTest.java @@ -6,7 +6,7 @@ import de.tum.cit.aet.artemis.core.domain.User; -public class ActivationMailTest extends AbstractMailContentTest { +class ActivationMailTest extends AbstractMailContentTest { @Test void testThatVariablesAreInjectedIntoTheTemplate() { diff --git a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportFailedMailTest.java b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportFailedMailTest.java index 02a23cc03df8..c5826bec402a 100644 --- a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportFailedMailTest.java +++ b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportFailedMailTest.java @@ -7,7 +7,7 @@ import de.tum.cit.aet.artemis.core.domain.DataExport; import de.tum.cit.aet.artemis.core.domain.User; -public class DataExportFailedMailTest extends AbstractMailContentTest { +class DataExportFailedMailTest extends AbstractMailContentTest { @Test void testThatVariablesAreInjectedIntoTheTemplate() { diff --git a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportSuccessfulMailTest.java b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportSuccessfulMailTest.java index a71fd1978fd8..3776addca809 100644 --- a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportSuccessfulMailTest.java +++ b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/DataExportSuccessfulMailTest.java @@ -4,13 +4,12 @@ import java.util.Set; -import org.jetbrains.annotations.NotNull; import org.junit.jupiter.api.Test; import de.tum.cit.aet.artemis.core.domain.DataExport; import de.tum.cit.aet.artemis.core.domain.User; -public class DataExportSuccessfulMailTest extends AbstractMailContentTest { +class DataExportSuccessfulMailTest extends AbstractMailContentTest { @Test void testThatVariablesAreInjectedIntoTheTemplate() { @@ -30,7 +29,6 @@ void testThatVariablesAreInjectedIntoTheTemplate() { assertThat(capturedContent).contains("test_subject_3"); } - @NotNull private static Set createThreeDataExportsWithThreeDifferentUsers() { User dataExportSubjectUser1 = new User(); User dataExportSubjectUser2 = new User(); diff --git a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/PasswordResetMailTest.java b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/PasswordResetMailTest.java index eac7abb673e1..b441153b1adf 100644 --- a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/PasswordResetMailTest.java +++ b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/PasswordResetMailTest.java @@ -6,7 +6,7 @@ import de.tum.cit.aet.artemis.core.domain.User; -public class PasswordResetMailTest extends AbstractMailContentTest { +class PasswordResetMailTest extends AbstractMailContentTest { @Test void testThatVariablesAreInjectedIntoTheTemplate() { diff --git a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/SAML2SetPasswordMailTest.java b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/SAML2SetPasswordMailTest.java index 398773409d99..cdb6eaacd6af 100644 --- a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/SAML2SetPasswordMailTest.java +++ b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/SAML2SetPasswordMailTest.java @@ -6,7 +6,7 @@ import de.tum.cit.aet.artemis.core.domain.User; -public class SAML2SetPasswordMailTest extends AbstractMailContentTest { +class SAML2SetPasswordMailTest extends AbstractMailContentTest { @Test void testThatVariablesAreInjectedIntoTheTemplate() { diff --git a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/WeeklySummaryMailTest.java b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/WeeklySummaryMailTest.java index 3169d71cae71..60fb5b75d66d 100644 --- a/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/WeeklySummaryMailTest.java +++ b/src/test/java/de/tum/cit/aet/artemis/communication/notifications/service/mail/WeeklySummaryMailTest.java @@ -13,7 +13,7 @@ import de.tum.cit.aet.artemis.quiz.domain.QuizExercise; import de.tum.cit.aet.artemis.text.domain.TextExercise; -public class WeeklySummaryMailTest extends AbstractMailContentTest { +class WeeklySummaryMailTest extends AbstractMailContentTest { @Test void testThatVariablesAreInjectedIntoTheTemplate() {