(self)
| 140 | c.start() |
| 141 | |
| 142 | def test_connection(self): |
| 143 | c = self.NoopConsumer() |
| 144 | |
| 145 | c.blueprint.start(c) |
| 146 | assert isinstance(c.connection, Connection) |
| 147 | |
| 148 | c.blueprint.state = RUN |
| 149 | c.event_dispatcher = None |
| 150 | c.blueprint.restart(c) |
| 151 | assert c.connection |
| 152 | |
| 153 | c.blueprint.state = RUN |
| 154 | c.shutdown() |
| 155 | assert c.connection is None |
| 156 | assert c.task_consumer is None |
| 157 | |
| 158 | c.blueprint.start(c) |
| 159 | assert isinstance(c.connection, Connection) |
| 160 | c.blueprint.restart(c) |
| 161 | |
| 162 | c.stop() |
| 163 | c.shutdown() |
| 164 | assert c.connection is None |
| 165 | assert c.task_consumer is None |
| 166 | |
| 167 | def test_close_connection(self): |
| 168 | c = self.NoopConsumer() |
nothing calls this directly
no test coverage detected