cheroot.test.test_makefile module#

Tests for cheroot.makefile.

class cheroot.test.test_makefile.MockSocket#

Bases: RawIOBase

A mock socket for testing stream I/O.

_abc_impl = <_abc._abc_data object>#
readable()#

Return True - supports reading.

readinto(buf)#

Read data into buffer.

writable()#

Return True - supports writing.

write(data)#

Write data (returns length written).

cheroot.test.test_makefile.test_bytes_read()#

Reader should capture bytes read.

cheroot.test.test_makefile.test_bytes_written()#

Writer should capture bytes written.