def test_preprocessor_does_nothing(): with patch.object(ignore, "ignored", set()): chan, nick, msg = ignore.ignore_preprocessor("#bots", "me", "foo") assert msg == "foo"
def test_preprocessor_blanks_message_when_ignored(): with patch.object(ignore, "ignored", set(["me"])): chan, nick, msg = ignore.ignore_preprocessor("#bots", "me", "foo") assert msg == ""