diff options
author | Thomas Hipp <thomashipp@gmail.com> | 2017-11-23 09:24:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-23 09:24:01 +0100 |
commit | bdbfc7ca1d4251fe5ecad10857ccec65a69afc65 (patch) | |
tree | 2fa527ca6fa4b238f357a7fb748741ff7be14ff3 /libvirt/resource_libvirt_domain_test.go | |
parent | 88c0dfcca51f4d301810380dacd119a9f291417c (diff) | |
parent | 5b215d3b86f285045fc5966de5d6ec3bf2f095da (diff) | |
download | terraform-provider-libvirt-bdbfc7ca1d4251fe5ecad10857ccec65a69afc65.tar terraform-provider-libvirt-bdbfc7ca1d4251fe5ecad10857ccec65a69afc65.tar.gz |
Merge pull request #241 from MalloZup/improve-codebase
remove duplicata declaration and simplify code.
Diffstat (limited to 'libvirt/resource_libvirt_domain_test.go')
-rw-r--r-- | libvirt/resource_libvirt_domain_test.go | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/libvirt/resource_libvirt_domain_test.go b/libvirt/resource_libvirt_domain_test.go index 65d9f898..2c9f1b52 100644 --- a/libvirt/resource_libvirt_domain_test.go +++ b/libvirt/resource_libvirt_domain_test.go @@ -26,7 +26,7 @@ func TestAccLibvirtDomain_Basic(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain-1", &domain), @@ -56,7 +56,7 @@ func TestAccLibvirtDomain_Detailed(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain-2", &domain), @@ -98,14 +98,14 @@ func TestAccLibvirtDomain_Volume(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: configVolAttached, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), testAccCheckLibvirtVolumeExists("libvirt_volume.acceptance-test-volume", &volume), ), }, - resource.TestStep{ + { Config: configVolDettached, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -150,7 +150,7 @@ func TestAccLibvirtDomain_VolumeTwoDisks(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: configVolAttached, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -158,7 +158,7 @@ func TestAccLibvirtDomain_VolumeTwoDisks(t *testing.T) { testAccCheckLibvirtVolumeExists("libvirt_volume.acceptance-test-volume2", &volume), ), }, - resource.TestStep{ + { Config: configVolDettached, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -191,7 +191,7 @@ func TestAccLibvirtDomain_ScsiDisk(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: configScsi, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -262,7 +262,7 @@ func TestAccLibvirtDomain_NetworkInterface(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -298,7 +298,7 @@ func TestAccLibvirtDomain_Graphics(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -374,7 +374,7 @@ func TestAccLibvirtDomain_Cpu(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -399,7 +399,7 @@ func TestAccLibvirtDomain_Autostart(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -433,7 +433,7 @@ func TestAccLibvirtDomain_Filesystems(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -479,7 +479,7 @@ func TestAccLibvirtDomain_Consoles(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -722,7 +722,7 @@ func subtestAccLibvirtDomainFirmwareNoTemplate(t *testing.T, NVRAMPath string, f Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -760,7 +760,7 @@ func subtestAccLibvirtDomainFirmwareTemplate(t *testing.T, NVRAMPath string, fir Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -793,7 +793,7 @@ func TestAccLibvirtDomain_MachineType(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), @@ -819,7 +819,7 @@ func TestAccLibvirtDomain_ArchType(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckLibvirtDomainDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: config, Check: resource.ComposeTestCheckFunc( testAccCheckLibvirtDomainExists("libvirt_domain.acceptance-test-domain", &domain), |