Compute Floating IP Test Update
Changes the test to require a network UUID rather than a name.
This commit is contained in:
parent
ef4e03a729
commit
99ac8b4410
|
@ -64,8 +64,8 @@ func testAccPreCheck(t *testing.T) {
|
||||||
t.Fatal("OS_FLAVOR_ID or OS_FLAVOR_NAME must be set for acceptance tests")
|
t.Fatal("OS_FLAVOR_ID or OS_FLAVOR_NAME must be set for acceptance tests")
|
||||||
}
|
}
|
||||||
|
|
||||||
v = os.Getenv("OS_NETWORK_NAME")
|
v = os.Getenv("OS_NETWORK_ID")
|
||||||
if v == "" {
|
if v == "" {
|
||||||
t.Fatal("OS_NETWORK_NAME must be set for acceptance tests")
|
t.Fatal("OS_NETWORK_ID must be set for acceptance tests")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,10 +67,10 @@ func TestAccComputeV2Instance_floatingIPAttach(t *testing.T) {
|
||||||
floating_ip = "${openstack_compute_floatingip_v2.myip.address}"
|
floating_ip = "${openstack_compute_floatingip_v2.myip.address}"
|
||||||
|
|
||||||
network {
|
network {
|
||||||
name = "%s"
|
uuid = "%s"
|
||||||
}
|
}
|
||||||
}`,
|
}`,
|
||||||
os.Getenv("OS_NETWORK_NAME"))
|
os.Getenv("OS_NETWORK_ID"))
|
||||||
|
|
||||||
resource.Test(t, resource.TestCase{
|
resource.Test(t, resource.TestCase{
|
||||||
PreCheck: func() { testAccPreCheck(t) },
|
PreCheck: func() { testAccPreCheck(t) },
|
||||||
|
|
Loading…
Reference in New Issue