human
I wrote the below code

    if (wraps is None):
        def wraps(*args, **kwargs):
            return None
    receiver = Mock(wraps=wraps)
    signal.connect(receiver, **kwargs)
    (yield receiver)
    signal.disconnect(receiver)

What's a good function header?
assistant
#Here's a good function header.

@contextmanager
def mock_signal_receiver(signal, wraps=None, **kwargs):