def test_signal_has_receivers_when_is_true(): test_signal = Signal() test_signal.connect(sender=Sender, receiver=coroutine_receiver) assert test_signal.has_receivers(sender=Sender) is True
def test_signal_has_receivers_when_is_false(): test_signal = Signal() assert test_signal.has_receivers(sender=Sender) is False