def METHOD_NAME(self):
    conn = ContextMock(name='connection')
    self.c.connection = conn
    conn.connection_errors = (KeyError,)
    conn.channel_errors = ()
    consume = self.c.consume = Mock(name='c.consume')
    with patch('kombu.mixins.sleep') as sleep:
        counter = [0]
        def se(*args, **kwargs):
            if counter[0] >= 1:
                self.c.should_stop = True
            counter[0] += 1
            return counter
        self.c.should_stop = False
        consume.side_effect = se
        self.c.run()
        sleep.assert_called()