(self)
| 817 | # Test the ping coroutine. |
| 818 | |
| 819 | def test_ping_default(self): |
| 820 | self.loop.run_until_complete(self.protocol.ping()) |
| 821 | # With our testing tools, it's more convenient to extract the expected |
| 822 | # ping data from the library's internals than from the frame sent. |
| 823 | ping_data = next(iter(self.protocol.pings)) |
| 824 | self.assertIsInstance(ping_data, bytes) |
| 825 | self.assertEqual(len(ping_data), 4) |
| 826 | self.assertOneFrameSent(True, OP_PING, ping_data) |
| 827 | |
| 828 | def test_ping_text(self): |
| 829 | self.loop.run_until_complete(self.protocol.ping("café")) |
nothing calls this directly
no test coverage detected