Compute Instance basic acceptance test

A change was made to account for clouds with multiple networks.
This commit is contained in:
Joe Topjian 2015-04-02 00:10:46 +00:00
parent 7ca97f4bfc
commit 1693767922
1 changed files with 11 additions and 10 deletions

View File

@ -17,6 +17,17 @@ import (
func TestAccComputeV2Instance_basic(t *testing.T) {
var instance servers.Server
var testAccComputeV2Instance_basic = fmt.Sprintf(`
resource "openstack_compute_instance_v2" "foo" {
name = "terraform-test"
network {
uuid = "%s"
}
metadata {
foo = "bar"
}
}`,
os.Getenv("OS_NETWORK_ID"))
resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
@ -207,16 +218,6 @@ func testAccCheckComputeV2InstanceFloatingIPAttach(
}
}
var testAccComputeV2Instance_basic = fmt.Sprintf(`
resource "openstack_compute_instance_v2" "foo" {
region = "%s"
name = "terraform-test"
metadata {
foo = "bar"
}
}`,
OS_REGION_NAME)
var testAccComputeV2Instance_volumeAttach = fmt.Sprintf(`
resource "openstack_blockstorage_volume_v1" "myvol" {
name = "myvol"