Move notifications test into notifications package

This commit is contained in:
Joseph Schorr 2017-07-14 16:16:37 +03:00
parent ce56031846
commit 5739e2ef4d
3 changed files with 176 additions and 184 deletions

View file

@ -67,6 +67,11 @@ class NotificationEvent(object):
raise InvalidNotificationEventException('Unable to find event: %s' % eventname)
@classmethod
def event_names(cls):
for subc in cls.__subclasses__():
if subc.event_name() is not None:
yield subc.event_name()
@staticmethod
def _get_event(cls, eventname):