Set public_network_name also when network ID is provided
Otherwise, when the code follows that branch, public_network_name won't be defined and an exception will be raised. Change-Id: I96007d74d78a42f4eb9543f52fae8f24a0161ac7
This commit is contained in:
parent
088ec97bf0
commit
71a40accec
|
@ -684,6 +684,7 @@ def create_tempest_networks(clients, conf, has_neutron, public_network_id):
|
|||
network_list = client.list_networks()
|
||||
for network in network_list['networks']:
|
||||
if network['id'] == public_network_id:
|
||||
public_network_name = network['name']
|
||||
break
|
||||
else:
|
||||
raise ValueError('provided network id: {0} was not found.'
|
||||
|
|
Loading…
Reference in New Issue