refactor: removed all references to CourseNotificationPreference (#37768)

This commit is contained in:
Ahtisham Shahid
2025-12-29 15:11:56 +05:00
committed by GitHub
parent 360a97fdd3
commit 9d2bbb1797
20 changed files with 81 additions and 953 deletions

View File

@@ -25,7 +25,7 @@ from cms.djangoapps.contentstore.utils import send_course_update_notification
from common.djangoapps.student.models import CourseEnrollment
from common.djangoapps.student.tests.factories import GlobalStaffFactory, InstructorFactory, UserFactory
from openedx.core.djangoapps.notifications.config.waffle import ENABLE_NOTIFICATIONS
from openedx.core.djangoapps.notifications.models import CourseNotificationPreference, Notification
from openedx.core.djangoapps.notifications.models import Notification
from openedx.core.djangoapps.site_configuration.tests.test_util import with_site_configuration_context
from xmodule.modulestore import ModuleStoreEnum # lint-amnesty, pylint: disable=wrong-import-order
from xmodule.modulestore.django import modulestore # lint-amnesty, pylint: disable=wrong-import-order
@@ -954,7 +954,6 @@ class CourseUpdateNotificationTests(OpenEdxEventsTestMixin, ModuleStoreTestCase)
super().setUp()
self.user = UserFactory()
self.course = CourseFactory.create(org='testorg', number='testcourse', run='testrun')
CourseNotificationPreference.objects.create(user_id=self.user.id, course_id=self.course.id)
def test_course_update_notification_sent(self):
"""