Comment 1 for bug 1676539

Revision history for this message
Curtis Hovey (sinzui) wrote :

ModelClient.add_cloud_interactive()'s vsphere block could expect
    "Enter the vCenter address or URL:|Enter the API endpoint url for the cloud:"
and
    "Enter region name:|Enter datacenter name:"
and other prompts
...
            if cloud['type'] == 'vsphere':
                child.expect('Enter the API endpoint url for the cloud:')
                child.sendline(cloud['endpoint'])
                for num, (name, values) in enumerate(cloud['regions'].items()):
                    child.expect("(Enter region name:)|"
                                 "(Can't validate endpoint)")
                    if child.match.group(2) is not None:
                        raise InvalidEndpoint()
                    child.sendline(name)
                    child.expect('Enter another region\? \(Y/n\):')
                    if num + 1 < len(cloud['regions']):
                        child.sendline('y')
                    else:
                        child.sendline('n')