@pytest.fixture(scope='module')
def net_connect(request):

    device_under_test = request.config.getoption('test_device')

    test_devices = parse_yaml(PWD + "/etc/test_devices.yml")
    device = test_devices[device_under_test]
    device['verbose'] = False

    conn = ConnectHandler(**device)

    return conn
Create the SSH connection to the remote device
dataset/ETHPy150Open ktbyers/netmiko/tests/conftest.py/net_connect