mirror of https://github.com/zulip/zulip.git
coverage: Bring test_events to 100% coverage.
This commit is contained in:
parent
d4f0e394e9
commit
768307d921
|
@ -86,7 +86,6 @@ not_yet_fully_covered = {
|
|||
'zerver/tests/test_bugdown.py',
|
||||
'zerver/tests/test_decorators.py',
|
||||
'zerver/tests/test_email_mirror.py',
|
||||
'zerver/tests/test_events.py',
|
||||
'zerver/tests/test_narrow.py',
|
||||
'zerver/tests/test_templates.py',
|
||||
'zerver/tests/test_tornado.py',
|
||||
|
|
|
@ -306,11 +306,11 @@ class EventsRegisterTest(ZulipTestCase):
|
|||
|
||||
if state_change_expected:
|
||||
if before == after:
|
||||
print(events)
|
||||
raise Exception('Test does not exercise enough code -- events do not change state.')
|
||||
print(events) # nocoverage
|
||||
raise AssertionError('Test does not exercise enough code -- events do not change state.')
|
||||
else:
|
||||
if before != after:
|
||||
raise Exception('Test is invalid--state actually does change here.')
|
||||
raise AssertionError('Test is invalid--state actually does change here.')
|
||||
|
||||
normal_state = fetch_initial_state_data(self.user_profile, event_types, "", include_subscribers=include_subscribers)
|
||||
self.match_states(hybrid_state, normal_state)
|
||||
|
|
Loading…
Reference in New Issue