# Path: catkin_tools/execution/io.py
# MAX_LOGFILE_HISTORY = 10
#     def _encode(string):
#     def _encode(string):
#     def __init__(self, label, job_id, stage_label, event_queue, log_path):
#     def close(self):
#     def get_interleaved_log(self):
#     def get_stdout_log(self):
#     def get_stderr_log(self):
#     def _encode(data):
#     def _decode(data):
#     def __del__(self):
#     def factory(cls, label, job_id, stage_label, event_queue, log_path):
#         def init_proxy(*args, **kwargs):
#     def __init__(self, label, job_id, stage_label, event_queue, log_path, *args, **kwargs):
#     def out(self, data, end='\n'):
#     def err(self, data, end='\n'):
#     def __init__(self, label, job_id, stage_label, event_queue, log_path, *args, **kwargs):
#     def _split(data):
#     def on_stdout_received(self, data):
#     def on_stderr_received(self, data):
#     def on_process_exited2(self, returncode):
#     def on_stdout_received(self, data):
# class IOBufferContainer(object):
# class IOBufferLogger(IOBufferContainer):
# class IOBufferProtocol(IOBufferContainer, AsyncSubprocessProtocol):
# class CatkinTestResultsIOBufferProtocol(IOBufferProtocol):


import binascii
from queue import Queue
from catkin_tools.execution import io as io



def test_invalid_utf8_characters():
    io_container = io.IOBufferContainer('test', 'test_id', 'test', Queue(), '/tmp')
    bad_byte_array = binascii.a2b_hex(b'80')
    try:

# Path: catkin_tools/execution/io.py
# MAX_LOGFILE_HISTORY = 10
#     def _encode(string):
#     def _encode(string):
#     def __init__(self, label, job_id, stage_label, event_queue, log_path):
#     def close(self):
#     def get_interleaved_log(self):
#     def get_stdout_log(self):
#     def get_stderr_log(self):
#     def _encode(data):
#     def _decode(data):
#     def __del__(self):
#     def factory(cls, label, job_id, stage_label, event_queue, log_path):
#         def init_proxy(*args, **kwargs):
#     def __init__(self, label, job_id, stage_label, event_queue, log_path, *args, **kwargs):
#     def out(self, data, end='\n'):
#     def err(self, data, end='\n'):
#     def __init__(self, label, job_id, stage_label, event_queue, log_path, *args, **kwargs):
#     def _split(data):
#     def on_stdout_received(self, data):
#     def on_stderr_received(self, data):
#     def on_process_exited2(self, returncode):
#     def on_stdout_received(self, data):
# class IOBufferContainer(object):
# class IOBufferLogger(IOBufferContainer):
# class IOBufferProtocol(IOBufferContainer, AsyncSubprocessProtocol):
# class CatkinTestResultsIOBufferProtocol(IOBufferProtocol):


# Path: tests/unit/test_io.py
import binascii
from queue import Queue
from catkin_tools.execution import io as io




def test_invalid_utf8_characters():
    io_container = io.IOBufferContainer('test', 'test_id', 'test', Queue(), '/tmp')
    bad_byte_array = binascii.a2b_hex(b'80')
    try:

        io_container._decode(bad_byte_array)