()
| 736 | await cond.acquire() |
| 737 | |
| 738 | async def wrong_loop_in_cond(): |
| 739 | # Same analogy here with the condition's loop. |
| 740 | lock = asyncio.Lock() |
| 741 | async with lock: |
| 742 | with self.assertRaises(TypeError): |
| 743 | asyncio.Condition(lock, loop=loop) |
| 744 | cond = asyncio.Condition(lock) |
| 745 | cond._loop = loop |
| 746 | with self.assertRaisesRegex( |
| 747 | RuntimeError, |
| 748 | "is bound to a different event loop", |
| 749 | ): |
| 750 | await cond.wait() |
| 751 | |
| 752 | await wrong_loop_in_lock() |
| 753 | await wrong_loop_in_cond() |
nothing calls this directly
no test coverage detected