Skip to content
This repository has been archived by the owner on May 12, 2022. It is now read-only.

Commit

Permalink
rename publish_notification_to_scope() to bulk_publish_notification_t…
Browse files Browse the repository at this point in the history
…o_scope() to keep naming more consistent
  • Loading branch information
Chris Dodge committed Mar 30, 2015
1 parent 8b0b10c commit e15d8ef
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion edx_notifications/lib/publisher.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def bulk_publish_notification_to_users(user_ids, msg, exclude_user_ids=None):


@contract(msg=NotificationMessage)
def publish_notification_to_scope(scope_name, scope_context, msg, exclude_user_ids=None):
def bulk_publish_notification_to_scope(scope_name, scope_context, msg, exclude_user_ids=None):
"""
This top level API method will publish a notification
to a UserScope (potentially large). Basically this is a convenience method
Expand Down
6 changes: 3 additions & 3 deletions edx_notifications/lib/tests/test_lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
publish_notification_to_user,
bulk_publish_notification_to_users,
register_notification_type,
publish_notification_to_scope,
bulk_publish_notification_to_scope,
)

from edx_notifications.lib.consumer import (
Expand Down Expand Up @@ -326,7 +326,7 @@ def test_publish_to_scope(self):
}
)

publish_notification_to_scope(
bulk_publish_notification_to_scope(
scope_name="list_scope",
# the TestListScopeResolver expects a "range" property in the context
scope_context={"range": 5},
Expand Down Expand Up @@ -357,7 +357,7 @@ def test_publish_to_bad_scope(self):
)

with self.assertRaises(TypeError):
publish_notification_to_scope(
bulk_publish_notification_to_scope(
scope_name="bad-scope",
# the TestListScopeResolver expects a "range" property in the context
scope_context={"range": 5},
Expand Down

0 comments on commit e15d8ef

Please sign in to comment.