@@ -22,6 +22,7 @@ const InternalClbNameUpdate = "tf-clb-update-internal"
22
22
const SingleClbName = "single-open-clb"
23
23
const MultiClbName = "multi-open-clb"
24
24
const OpenClbName = "tf-clb-open"
25
+ const OpenClbNameIpv6 = "tf-clb-open-ipv6"
25
26
const OpenClbNameUpdate = "tf-clb-update-open"
26
27
27
28
func init () {
@@ -158,6 +159,30 @@ func TestAccTencentCloudClbInstanceResource_open(t *testing.T) {
158
159
})
159
160
}
160
161
162
+ func TestAccTencentCloudClbInstanceResource_openIpv6 (t * testing.T ) {
163
+ t .Parallel ()
164
+
165
+ resource .Test (t , resource.TestCase {
166
+ PreCheck : func () { tcacctest .AccPreCheck (t ) },
167
+ Providers : tcacctest .AccProviders ,
168
+ CheckDestroy : testAccCheckClbInstanceDestroy ,
169
+ Steps : []resource.TestStep {
170
+ {
171
+ Config : testAccClbInstance_openIpv6 ,
172
+ Check : resource .ComposeTestCheckFunc (
173
+ testAccCheckClbInstanceExists ("tencentcloud_clb_instance.clb_open_ipv6" ),
174
+ resource .TestCheckResourceAttr ("tencentcloud_clb_instance.clb_open_ipv6" , "network_type" , "OPEN" ),
175
+ resource .TestCheckResourceAttr ("tencentcloud_clb_instance.clb_open_ipv6" , "clb_name" , OpenClbNameIpv6 ),
176
+ resource .TestCheckResourceAttr ("tencentcloud_clb_instance.clb_open_ipv6" , "project_id" , "0" ),
177
+ resource .TestCheckResourceAttr ("tencentcloud_clb_instance.clb_open_ipv6" , "vpc_id" , "vpc-mvhjjprd" ),
178
+ resource .TestCheckResourceAttr ("tencentcloud_clb_instance.clb_open_ipv6" , "subnet_id" , "subnet-2qfyfvv8" ),
179
+ resource .TestCheckResourceAttr ("tencentcloud_clb_instance.clb_open_ipv6" , "address_ip_version" , "IPv6FullChain" ),
180
+ ),
181
+ },
182
+ },
183
+ })
184
+ }
185
+
161
186
func TestAccTencentCloudClbInstanceResource_snat (t * testing.T ) {
162
187
t .Parallel ()
163
188
@@ -629,3 +654,14 @@ resource "tencentcloud_clb_instance" "multiple_instance" {
629
654
}
630
655
}
631
656
`
657
+
658
+ const testAccClbInstance_openIpv6 = `
659
+ resource "tencentcloud_clb_instance" "clb_open_ipv6" {
660
+ clb_name = "` + OpenClbNameIpv6 + `"
661
+ network_type = "OPEN"
662
+ project_id = 0
663
+ vpc_id = "vpc-mvhjjprd"
664
+ subnet_id = "subnet-2qfyfvv8"
665
+ address_ip_version = "IPv6FullChain"
666
+ }
667
+ `
0 commit comments