(self)
| 606 | self.assertEqual(data, [b'1', b'9']) |
| 607 | |
| 608 | def test_idle_delayed_packet(self): |
| 609 | client, _ = self._setup(IdleCmdDelayedPacketHandler) |
| 610 | client.login('user', 'pass') |
| 611 | # If our readline() implementation fails to preserve line fragments |
| 612 | # when idle timeouts trigger, a response spanning delayed packets |
| 613 | # can be corrupted, leaving the protocol stream in a bad state. |
| 614 | try: |
| 615 | with client.idle(0.5) as idler: |
| 616 | self.assertRaises(StopIteration, next, idler) |
| 617 | except client.abort as err: |
| 618 | self.fail('multi-packet response was corrupted by idle timeout') |
| 619 | |
| 620 | def test_login(self): |
| 621 | client, _ = self._setup(SimpleIMAPHandler) |
nothing calls this directly
no test coverage detected