MCPcopy
hub / github.com/aio-libs/aiohttp / test_send_bytes_nonbytes

Method test_send_bytes_nonbytes

tests/test_web_websocket.py:138–143  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

136 ws.send_str(b'bytes')
137
138 def test_send_bytes_nonbytes(self):
139 req = self.make_request('GET', '/')
140 ws = WebSocketResponse()
141 self.loop.run_until_complete(ws.prepare(req))
142 with self.assertRaises(TypeError):
143 ws.send_bytes('string')
144
145 def test_write(self):
146 ws = WebSocketResponse()

Callers

nothing calls this directly

Calls 4

make_requestMethod · 0.95
prepareMethod · 0.95
send_bytesMethod · 0.95
WebSocketResponseClass · 0.90

Tested by

no test coverage detected