@@ -25,7 +25,7 @@ func TestAccECSClusterCapacityProviders_basic(t *testing.T) {
2525 CheckDestroy : testAccCheckClusterDestroy ,
2626 Steps : []resource.TestStep {
2727 {
28- Config : testAccClusterCapacityProvidersConfig (rName ),
28+ Config : testAccClusterCapacityProvidersConfig_basic (rName ),
2929 Check : resource .ComposeTestCheckFunc (
3030 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
3131 resource .TestCheckResourceAttr (resourceName , "capacity_providers.#" , "1" ),
@@ -60,7 +60,7 @@ func TestAccECSClusterCapacityProviders_disappears(t *testing.T) {
6060 CheckDestroy : testAccCheckClusterDestroy ,
6161 Steps : []resource.TestStep {
6262 {
63- Config : testAccClusterCapacityProvidersConfig (rName ),
63+ Config : testAccClusterCapacityProvidersConfig_basic (rName ),
6464 Check : resource .ComposeTestCheckFunc (
6565 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
6666 acctest .CheckResourceDisappears (acctest .Provider , tfecs .ResourceCluster (), resourceName ),
@@ -117,7 +117,7 @@ func TestAccECSClusterCapacityProviders_destroy(t *testing.T) {
117117 CheckDestroy : testAccCheckClusterDestroy ,
118118 Steps : []resource.TestStep {
119119 {
120- Config : testAccClusterCapacityProvidersConfig_destroy_before (rName ),
120+ Config : testAccClusterCapacityProvidersConfig_destroyBefore (rName ),
121121 Check : resource .ComposeTestCheckFunc (
122122 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
123123 func (s * terraform.State ) error {
@@ -130,7 +130,7 @@ func TestAccECSClusterCapacityProviders_destroy(t *testing.T) {
130130 ),
131131 },
132132 {
133- Config : testAccClusterCapacityProvidersConfig_destroy_after (rName ),
133+ Config : testAccClusterCapacityProvidersConfig_destroyAfter (rName ),
134134 },
135135 },
136136 })
@@ -148,7 +148,7 @@ func TestAccECSClusterCapacityProviders_Update_capacityProviders(t *testing.T) {
148148 CheckDestroy : testAccCheckClusterDestroy ,
149149 Steps : []resource.TestStep {
150150 {
151- Config : testAccClusterCapacityProvidersConfig_withCapacityProviders1 (rName , "FARGATE" ),
151+ Config : testAccClusterCapacityProvidersConfig_1 (rName , "FARGATE" ),
152152 Check : resource .ComposeTestCheckFunc (
153153 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
154154 resource .TestCheckResourceAttr (resourceName , "capacity_providers.#" , "1" ),
@@ -161,7 +161,7 @@ func TestAccECSClusterCapacityProviders_Update_capacityProviders(t *testing.T) {
161161 ImportStateVerify : true ,
162162 },
163163 {
164- Config : testAccClusterCapacityProvidersConfig_withCapacityProviders2 (rName , "FARGATE" , "FARGATE_SPOT" ),
164+ Config : testAccClusterCapacityProvidersConfig_2 (rName , "FARGATE" , "FARGATE_SPOT" ),
165165 Check : resource .ComposeTestCheckFunc (
166166 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
167167 resource .TestCheckResourceAttr (resourceName , "capacity_providers.#" , "2" ),
@@ -175,7 +175,7 @@ func TestAccECSClusterCapacityProviders_Update_capacityProviders(t *testing.T) {
175175 ImportStateVerify : true ,
176176 },
177177 {
178- Config : testAccClusterCapacityProvidersConfig_withCapacityProviders0 (rName ),
178+ Config : testAccClusterCapacityProvidersConfig_0 (rName ),
179179 Check : resource .ComposeTestCheckFunc (
180180 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
181181 resource .TestCheckResourceAttr (resourceName , "capacity_providers.#" , "0" ),
@@ -187,7 +187,7 @@ func TestAccECSClusterCapacityProviders_Update_capacityProviders(t *testing.T) {
187187 ImportStateVerify : true ,
188188 },
189189 {
190- Config : testAccClusterCapacityProvidersConfig_withCapacityProviders1 (rName , "FARGATE" ),
190+ Config : testAccClusterCapacityProvidersConfig_1 (rName , "FARGATE" ),
191191 Check : resource .ComposeTestCheckFunc (
192192 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
193193 resource .TestCheckResourceAttr (resourceName , "capacity_providers.#" , "1" ),
@@ -215,7 +215,7 @@ func TestAccECSClusterCapacityProviders_Update_defaultStrategy(t *testing.T) {
215215 CheckDestroy : testAccCheckClusterDestroy ,
216216 Steps : []resource.TestStep {
217217 {
218- Config : testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy1 (rName ),
218+ Config : testAccClusterCapacityProvidersConfig_defaultProviderStrategy1 (rName ),
219219 Check : resource .ComposeTestCheckFunc (
220220 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
221221 resource .TestCheckResourceAttr (resourceName , "default_capacity_provider_strategy.#" , "1" ),
@@ -232,7 +232,7 @@ func TestAccECSClusterCapacityProviders_Update_defaultStrategy(t *testing.T) {
232232 ImportStateVerify : true ,
233233 },
234234 {
235- Config : testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy2 (rName ),
235+ Config : testAccClusterCapacityProvidersConfig_defaultProviderStrategy2 (rName ),
236236 Check : resource .ComposeTestCheckFunc (
237237 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
238238 resource .TestCheckResourceAttr (resourceName , "default_capacity_provider_strategy.#" , "2" ),
@@ -254,7 +254,7 @@ func TestAccECSClusterCapacityProviders_Update_defaultStrategy(t *testing.T) {
254254 ImportStateVerify : true ,
255255 },
256256 {
257- Config : testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy3 (rName ),
257+ Config : testAccClusterCapacityProvidersConfig_defaultProviderStrategy3 (rName ),
258258 Check : resource .ComposeTestCheckFunc (
259259 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
260260 resource .TestCheckResourceAttr (resourceName , "default_capacity_provider_strategy.#" , "2" ),
@@ -276,7 +276,7 @@ func TestAccECSClusterCapacityProviders_Update_defaultStrategy(t *testing.T) {
276276 ImportStateVerify : true ,
277277 },
278278 {
279- Config : testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy4 (rName ),
279+ Config : testAccClusterCapacityProvidersConfig_defaultProviderStrategy4 (rName ),
280280 Check : resource .ComposeTestCheckFunc (
281281 testAccCheckClusterExists ("aws_ecs_cluster.test" , & cluster ),
282282 resource .TestCheckResourceAttr (resourceName , "default_capacity_provider_strategy.#" , "0" ),
@@ -291,7 +291,7 @@ func TestAccECSClusterCapacityProviders_Update_defaultStrategy(t *testing.T) {
291291 })
292292}
293293
294- func testAccClusterCapacityProvidersConfig (rName string ) string {
294+ func testAccClusterCapacityProvidersConfig_basic (rName string ) string {
295295 return fmt .Sprintf (`
296296resource "aws_ecs_cluster" "test" {
297297 name = %[1]q
@@ -323,7 +323,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
323323` , rName )
324324}
325325
326- func testAccClusterCapacityProvidersConfig_withCapacityProviders0 (rName string ) string {
326+ func testAccClusterCapacityProvidersConfig_0 (rName string ) string {
327327 return fmt .Sprintf (`
328328resource "aws_ecs_cluster" "test" {
329329 name = %[1]q
@@ -337,7 +337,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
337337` , rName )
338338}
339339
340- func testAccClusterCapacityProvidersConfig_withCapacityProviders1 (rName , provider1 string ) string {
340+ func testAccClusterCapacityProvidersConfig_1 (rName , provider1 string ) string {
341341 return fmt .Sprintf (`
342342resource "aws_ecs_cluster" "test" {
343343 name = %[1]q
@@ -351,7 +351,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
351351` , rName , provider1 )
352352}
353353
354- func testAccClusterCapacityProvidersConfig_withCapacityProviders2 (rName , provider1 , provider2 string ) string {
354+ func testAccClusterCapacityProvidersConfig_2 (rName , provider1 , provider2 string ) string {
355355 return fmt .Sprintf (`
356356resource "aws_ecs_cluster" "test" {
357357 name = %[1]q
@@ -365,7 +365,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
365365` , rName , provider1 , provider2 )
366366}
367367
368- func testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy1 (rName string ) string {
368+ func testAccClusterCapacityProvidersConfig_defaultProviderStrategy1 (rName string ) string {
369369 return fmt .Sprintf (`
370370resource "aws_ecs_cluster" "test" {
371371 name = %[1]q
@@ -385,7 +385,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
385385` , rName )
386386}
387387
388- func testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy2 (rName string ) string {
388+ func testAccClusterCapacityProvidersConfig_defaultProviderStrategy2 (rName string ) string {
389389 return fmt .Sprintf (`
390390resource "aws_ecs_cluster" "test" {
391391 name = %[1]q
@@ -410,7 +410,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
410410` , rName )
411411}
412412
413- func testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy3 (rName string ) string {
413+ func testAccClusterCapacityProvidersConfig_defaultProviderStrategy3 (rName string ) string {
414414 return fmt .Sprintf (`
415415resource "aws_ecs_cluster" "test" {
416416 name = %[1]q
@@ -435,7 +435,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
435435` , rName )
436436}
437437
438- func testAccClusterCapacityProvidersConfig_withDefaultCapacityProviderStrategy4 (rName string ) string {
438+ func testAccClusterCapacityProvidersConfig_defaultProviderStrategy4 (rName string ) string {
439439 return fmt .Sprintf (`
440440resource "aws_ecs_cluster" "test" {
441441 name = %[1]q
@@ -449,7 +449,7 @@ resource "aws_ecs_cluster_capacity_providers" "test" {
449449` , rName )
450450}
451451
452- func testAccClusterCapacityProvidersConfig_destroy_before (rName string ) string {
452+ func testAccClusterCapacityProvidersConfig_destroyBefore (rName string ) string {
453453 return fmt .Sprintf (`
454454data "aws_ami" "test" {
455455 most_recent = true
@@ -609,7 +609,7 @@ resource "aws_autoscaling_group" "test" {
609609` , rName )
610610}
611611
612- func testAccClusterCapacityProvidersConfig_destroy_after (rName string ) string {
612+ func testAccClusterCapacityProvidersConfig_destroyAfter (rName string ) string {
613613 return fmt .Sprintf (`
614614resource "aws_vpc" "test" {
615615 cidr_block = "10.0.0.0/16"
0 commit comments