Instead of mocking out write_bytes, read_bytes, and read_line, we use
a fake serial port implementation that uses a pair of io.BytesIO
objects. This means we're actually running the send_bytes, etc,
methods, rather than excluding them from testing via mocks.
Instead of mocking out write_bytes, read_bytes, and read_line, we use a fake serial port implementation that uses a pair of io.BytesIO objects. This means we're actually running the send_bytes, etc, methods, rather than excluding them from testing via mocks.