@@ -22,6 +22,7 @@ const InternalClbNameUpdate = "tf-clb-update-internal"
2222const SingleClbName = "single-open-clb"
2323const MultiClbName = "multi-open-clb"
2424const OpenClbName = "tf-clb-open"
25+ const OpenClbNameIpv6 = "tf-clb-open-ipv6"
2526const OpenClbNameUpdate = "tf-clb-update-open"
2627
2728func init () {
@@ -158,6 +159,30 @@ func TestAccTencentCloudClbInstanceResource_open(t *testing.T) {
158159 })
159160}
160161
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+
161186func TestAccTencentCloudClbInstanceResource_snat (t * testing.T ) {
162187 t .Parallel ()
163188
@@ -629,3 +654,14 @@ resource "tencentcloud_clb_instance" "multiple_instance" {
629654 }
630655}
631656`
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