(self)
| 83 | self.assertEqual(asyncio.run(main()), 42) |
| 84 | |
| 85 | def test_asyncio_run_raises(self): |
| 86 | async def main(): |
| 87 | await asyncio.sleep(0) |
| 88 | raise ValueError('spam') |
| 89 | |
| 90 | with self.assertRaisesRegex(ValueError, 'spam'): |
| 91 | asyncio.run(main()) |
| 92 | |
| 93 | def test_asyncio_run_only_coro(self): |
| 94 | for o in {1, lambda: None}: |
nothing calls this directly
no test coverage detected