Exemple #1
0
 def test_ping_frame_has_no_less_than_body_length_8(self):
     f = PingFrame()
     with pytest.raises(ValueError):
         f.parse_body(b'\x01\x02\x03\x04\x05\x06\x07')
 def test_ping_frame_has_no_more_than_body_length_8(self):
     f = PingFrame(0)
     with pytest.raises(ValueError):
         f.parse_body(b'\x01\x02\x03\x04\x05\x06\x07\x08\x09')
Exemple #3
0
 def test_ping_frame_has_no_more_than_body_length_8(self):
     f = PingFrame()
     with pytest.raises(InvalidFrameError):
         f.parse_body(b'\x01\x02\x03\x04\x05\x06\x07\x08\x09')