@@ -627,8 +627,8 @@ func testCreateNodeBalancerWithVPCBackend(t *testing.T, client *linodego.Client,
627627 Options .VPCNames = vpcNames
628628 Options .SubnetNames = subnetNames
629629 }()
630- Options .VPCNames = "test1"
631- Options .SubnetNames = defaultSubnet
630+ Options .VPCNames = [] string { "test1" }
631+ Options .SubnetNames = [] string { defaultSubnet }
632632 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
633633 Label : "test1" ,
634634 Description : "" ,
@@ -669,8 +669,8 @@ func testUpdateNodeBalancerWithVPCBackend(t *testing.T, client *linodego.Client,
669669 Options .VPCNames = vpcNames
670670 Options .SubnetNames = subnetNames
671671 }()
672- Options .VPCNames = "test1"
673- Options .SubnetNames = defaultSubnet
672+ Options .VPCNames = [] string { "test1" }
673+ Options .SubnetNames = [] string { defaultSubnet }
674674 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
675675 Label : "test1" ,
676676 Description : "" ,
@@ -757,8 +757,8 @@ func testCreateNodeBalancerWithVPCOnlySubnetFlag(t *testing.T, client *linodego.
757757 Options .SubnetNames = subnetNames
758758 Options .NodeBalancerBackendIPv4Subnet = nbBackendSubnet
759759 }()
760- Options .VPCNames = "test-subflag"
761- Options .SubnetNames = defaultSubnet
760+ Options .VPCNames = [] string { "test-subflag" }
761+ Options .SubnetNames = [] string { defaultSubnet }
762762 Options .NodeBalancerBackendIPv4Subnet = "10.254.0.0/24"
763763 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
764764 Label : "test-subflag" ,
@@ -851,8 +851,8 @@ func testCreateNodeBalancerWithVPCNoFlagOrAnnotation(t *testing.T, client *linod
851851 Options .VPCNames = vpcNames
852852 Options .SubnetNames = subnetNames
853853 }()
854- Options .VPCNames = "test-noflags"
855- Options .SubnetNames = defaultSubnet
854+ Options .VPCNames = [] string { "test-noflags" }
855+ Options .SubnetNames = [] string { defaultSubnet }
856856 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
857857 Label : "test-noflags" ,
858858 Description : "" ,
@@ -934,8 +934,8 @@ func testCreateNodeBalancerWithVPCAnnotationOnly(t *testing.T, client *linodego.
934934 Options .VPCNames = vpcNames
935935 Options .SubnetNames = subnetNames
936936 }()
937- Options .VPCNames = "test-onlyannotation"
938- Options .SubnetNames = defaultSubnet
937+ Options .VPCNames = [] string { "test-onlyannotation" }
938+ Options .SubnetNames = [] string { defaultSubnet }
939939 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
940940 Label : "test-onlyannotation" ,
941941 Description : "" ,
@@ -1024,8 +1024,8 @@ func testCreateNodeBalancerWithVPCOnlySubnetIDFlag(t *testing.T, client *linodeg
10241024 Options .SubnetNames = subnetNames
10251025 Options .NodeBalancerBackendIPv4SubnetID = nbBackendSubnetID
10261026 }()
1027- Options .VPCNames = "test1"
1028- Options .SubnetNames = defaultSubnet
1027+ Options .VPCNames = [] string { "test1" }
1028+ Options .SubnetNames = [] string { defaultSubnet }
10291029 Options .NodeBalancerBackendIPv4SubnetID = 1111
10301030 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
10311031 Label : "test-subid-flag" ,
@@ -1105,12 +1105,15 @@ func testCreateNodeBalancerWithVPCAnnotationOverwrite(t *testing.T, client *lino
11051105
11061106 // provision multiple vpcs
11071107 vpcNames := Options .VPCNames
1108+ subnetNames := Options .SubnetNames
11081109 nodebalancerBackendIPv4Subnet := Options .NodeBalancerBackendIPv4Subnet
11091110 defer func () {
11101111 Options .VPCNames = vpcNames
1112+ Options .SubnetNames = subnetNames
11111113 Options .NodeBalancerBackendIPv4Subnet = nodebalancerBackendIPv4Subnet
11121114 }()
1113- Options .VPCNames = "test1"
1115+ Options .VPCNames = []string {"test1" }
1116+ Options .SubnetNames = []string {defaultSubnet }
11141117 Options .NodeBalancerBackendIPv4Subnet = "10.100.0.0/24"
11151118
11161119 _ , _ = client .CreateVPC (t .Context (), linodego.VPCCreateOptions {
0 commit comments