| 1 |
"""Test _admins_to_notify wrapper functionality""" |
| 2 |
import pytest |
| 3 |
|
| 4 |
extra_config = {"BOT_ADMINS_NOTIFICATIONS": "zoni@localdomain"} |
| 5 |
|
| 6 |
|
| 7 |
def test_admins_to_notify(testbot): |
| 8 |
"""Test which admins will be notified""" |
| 9 |
notified_admins = testbot._bot._admins_to_notify() |
| 10 |
assert "zoni@localdomain" in notified_admins |
| 11 |
|
| 12 |
|
| 13 |
def test_admins_not_notified(testbot): |
| 14 |
"""Test which admins will not be notified""" |
| 15 |
notified_admins = testbot._bot._admins_to_notify() |
| 16 |
assert "gbin@local" not in notified_admins |