From 2bd73ca96bf06cf57930175cba692e358c1e578e Mon Sep 17 00:00:00 2001 From: Ahtisham Shahid Date: Wed, 1 May 2024 01:38:30 +0500 Subject: [PATCH] change notification app name (#34672) --- .../djangoapps/notifications/base_notification.py | 6 +++--- .../djangoapps/notifications/tests/test_views.py | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/openedx/core/djangoapps/notifications/base_notification.py b/openedx/core/djangoapps/notifications/base_notification.py index 3f080aab81..2845e9cbe4 100644 --- a/openedx/core/djangoapps/notifications/base_notification.py +++ b/openedx/core/djangoapps/notifications/base_notification.py @@ -187,7 +187,7 @@ COURSE_NOTIFICATION_TYPES = { 'filters': [FILTER_AUDIT_EXPIRED_USERS_WITH_NO_ROLE] }, 'ora_staff_notification': { - 'notification_app': 'ora', + 'notification_app': 'grading', 'name': 'ora_staff_notification', 'is_core': False, 'info': '', @@ -227,9 +227,9 @@ COURSE_NOTIFICATION_APPS = { 'core_email_cadence': EmailCadence.DAILY, 'non_editable': [] }, - 'ora': { + 'grading': { 'enabled': True, - 'core_info': _('Notifications for Open response submissions.'), + 'core_info': _('Notifications for submission grading.'), 'core_web': True, 'core_email': True, 'core_push': True, diff --git a/openedx/core/djangoapps/notifications/tests/test_views.py b/openedx/core/djangoapps/notifications/tests/test_views.py index 8dcb335f5f..ca5572ed9f 100644 --- a/openedx/core/djangoapps/notifications/tests/test_views.py +++ b/openedx/core/djangoapps/notifications/tests/test_views.py @@ -298,7 +298,7 @@ class UserNotificationPreferenceAPITest(ModuleStoreTestCase): }, 'non_editable': {} }, - 'ora': { + 'grading': { 'enabled': True, 'core_notification_types': [], 'notification_types': { @@ -314,7 +314,7 @@ class UserNotificationPreferenceAPITest(ModuleStoreTestCase): 'email': True, 'push': True, 'email_cadence': 'Daily', - 'info': 'Notifications for Open response submissions.' + 'info': 'Notifications for submission grading.' } }, 'non_editable': {} @@ -601,7 +601,7 @@ class UserNotificationChannelPreferenceAPITest(ModuleStoreTestCase): }, 'non_editable': {} }, - 'ora': { + 'grading': { 'enabled': True, 'core_notification_types': [], 'notification_types': { @@ -617,7 +617,7 @@ class UserNotificationChannelPreferenceAPITest(ModuleStoreTestCase): 'email': True, 'push': True, 'email_cadence': 'Daily', - 'info': 'Notifications for Open response submissions.' + 'info': 'Notifications for submission grading.' } }, 'non_editable': {} @@ -926,7 +926,7 @@ class NotificationCountViewSetTestCase(ModuleStoreTestCase): self.assertEqual(response.status_code, 200) self.assertEqual(response.data['count'], 4) self.assertEqual(response.data['count_by_app_name'], { - 'App Name 1': 2, 'App Name 2': 1, 'App Name 3': 1, 'discussion': 0, 'updates': 0, 'ora': 0}) + 'App Name 1': 2, 'App Name 2': 1, 'App Name 3': 1, 'discussion': 0, 'updates': 0, 'grading': 0}) self.assertEqual(response.data['show_notifications_tray'], show_notifications_tray_enabled) def test_get_unseen_notifications_count_for_unauthenticated_user(self): @@ -947,7 +947,7 @@ class NotificationCountViewSetTestCase(ModuleStoreTestCase): self.assertEqual(response.status_code, 200) self.assertEqual(response.data['count'], 0) - self.assertEqual(response.data['count_by_app_name'], {'discussion': 0, 'updates': 0, 'ora': 0}) + self.assertEqual(response.data['count_by_app_name'], {'discussion': 0, 'updates': 0, 'grading': 0}) def test_get_expiry_days_in_count_view(self): """