Exemplo n.º 1
0
def test_export_network_serial(target):
    NetworkSerialPort(target, None, host='testhost', port=12345, speed=115200)
    SerialDriver(target, None)

    exported = target.export()
    assert exported == {
        'LG__SERIALDRIVER_HOST': 'testhost',
        'LG__SERIALDRIVER_PORT': '12345',
        'LG__SERIALDRIVER_PROTOCOL': 'rfc2217',
        'LG__SERIALDRIVER_SPEED': '115200'
    }
Exemplo n.º 2
0
def serial_raw_port(target):
    return NetworkSerialPort(target,
                             'serialraw',
                             host='localhost',
                             port=8888,
                             protocol="raw")
Exemplo n.º 3
0
def serial_rfc2711_port(target):
    return NetworkSerialPort(target, 'rfc2711', host='localhost', port=8888)