(self)
| 263 | assert excinfo.typename == 'KeyError' |
| 264 | |
| 265 | def test_raising_remote_tracebacks(self): |
| 266 | pytest.importorskip('tblib') |
| 267 | |
| 268 | withtb = self.app.AsyncResult(self.task5['id']) |
| 269 | self.app.conf.task_remote_tracebacks = True |
| 270 | with pytest.raises(KeyError) as excinfo: |
| 271 | withtb.get() |
| 272 | tb = [t.strip() for t in traceback.format_tb(excinfo.tb)] |
| 273 | assert 'File "foo.py", line 2, in foofunc' in tb |
| 274 | assert 'File "bar.py", line 3, in barfunc' in tb |
| 275 | assert excinfo.value.args[0] == 'blue' |
| 276 | assert excinfo.typename == 'KeyError' |
| 277 | |
| 278 | def test_str(self): |
| 279 | ok_res = self.app.AsyncResult(self.task1['id']) |
nothing calls this directly
no test coverage detected