File: core_test.py

package info (click to toggle)
errbot 6.1.7%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 3,712 kB
  • sloc: python: 13,831; makefile: 164; sh: 97
file content (16 lines) | stat: -rwxr-xr-x 509 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
"""Test _admins_to_notify wrapper functionality"""
import pytest

extra_config = {"BOT_ADMINS_NOTIFICATIONS": "zoni@localdomain"}


def test_admins_to_notify(testbot):
    """Test which admins will be notified"""
    notified_admins = testbot._bot._admins_to_notify()
    assert "zoni@localdomain" in notified_admins


def test_admins_not_notified(testbot):
    """Test which admins will not be notified"""
    notified_admins = testbot._bot._admins_to_notify()
    assert "gbin@local" not in notified_admins