From 75aab3d05e4551702a1cef000c87d819f968d360 Mon Sep 17 00:00:00 2001 From: Atul Bhosale Date: Sat, 5 Sep 2020 23:33:18 +0530 Subject: [PATCH] Rename aci_switch_association to aci_leaf_selector --- aci/provider.go | 4 ++-- aci/resource_aci_infraleafs_test.go | 16 ++++++++-------- aci/resource_aci_infranodeblk_test.go | 4 ++-- website/aci.erb | 8 ++++---- website/docs/d/infraleafs.html.markdown | 12 ++++++------ website/docs/d/infranodeblk.html.markdown | 2 +- website/docs/r/infraleafs.html.markdown | 16 ++++++++-------- website/docs/r/infranodeblk.html.markdown | 4 ++-- 8 files changed, 33 insertions(+), 33 deletions(-) diff --git a/aci/provider.go b/aci/provider.go index 970ffd152..b813e8bb4 100644 --- a/aci/provider.go +++ b/aci/provider.go @@ -111,7 +111,7 @@ func Provider() terraform.ResourceProvider { "aci_action_rule_profile": resourceAciActionRuleProfile(), "aci_trigger_scheduler": resourceAciTriggerScheduler(), "aci_taboo_contract": resourceAciTabooContract(), - "aci_switch_association": resourceAciSwitchAssociation(), + "aci_leaf_selector": resourceAciSwitchAssociation(), "aci_span_destination_group": resourceAciSPANDestinationGroup(), "aci_span_source_group": resourceAciSPANSourceGroup(), "aci_span_sourcedestination_group_match_label": resourceAciSPANSourcedestinationGroupMatchLabel(), @@ -209,7 +209,7 @@ func Provider() terraform.ResourceProvider { "aci_action_rule_profile": dataSourceAciActionRuleProfile(), "aci_trigger_scheduler": dataSourceAciTriggerScheduler(), "aci_taboo_contract": dataSourceAciTabooContract(), - "aci_switch_association": dataSourceAciSwitchAssociation(), + "aci_leaf_selector": dataSourceAciSwitchAssociation(), "aci_span_destination_group": dataSourceAciSPANDestinationGroup(), "aci_span_source_group": dataSourceAciSPANSourceGroup(), "aci_span_sourcedestination_group_match_label": dataSourceAciSPANSourcedestinationGroupMatchLabel(), diff --git a/aci/resource_aci_infraleafs_test.go b/aci/resource_aci_infraleafs_test.go index dc42ca460..72cc03935 100644 --- a/aci/resource_aci_infraleafs_test.go +++ b/aci/resource_aci_infraleafs_test.go @@ -22,12 +22,12 @@ func TestAccAciSwitchAssociation_Basic(t *testing.T) { { Config: testAccCheckAciSwitchAssociationConfig_basic(description), Check: resource.ComposeTestCheckFunc( - testAccCheckAciSwitchAssociationExists("aci_switch_association.fooswitch_association", &switch_association), + testAccCheckAciSwitchAssociationExists("aci_leaf_selector.fooswitch_association", &switch_association), testAccCheckAciSwitchAssociationAttributes(description, &switch_association), ), }, { - ResourceName: "aci_switch_association", + ResourceName: "aci_leaf_selector", ImportState: true, ImportStateVerify: true, }, @@ -47,14 +47,14 @@ func TestAccAciSwitchAssociation_update(t *testing.T) { { Config: testAccCheckAciSwitchAssociationConfig_basic(description), Check: resource.ComposeTestCheckFunc( - testAccCheckAciSwitchAssociationExists("aci_switch_association.fooswitch_association", &switch_association), + testAccCheckAciSwitchAssociationExists("aci_leaf_selector.fooswitch_association", &switch_association), testAccCheckAciSwitchAssociationAttributes(description, &switch_association), ), }, { Config: testAccCheckAciSwitchAssociationConfig_basic(description), Check: resource.ComposeTestCheckFunc( - testAccCheckAciSwitchAssociationExists("aci_switch_association.fooswitch_association", &switch_association), + testAccCheckAciSwitchAssociationExists("aci_leaf_selector.fooswitch_association", &switch_association), testAccCheckAciSwitchAssociationAttributes(description, &switch_association), ), }, @@ -65,12 +65,12 @@ func TestAccAciSwitchAssociation_update(t *testing.T) { func testAccCheckAciSwitchAssociationConfig_basic(description string) string { return fmt.Sprintf(` - resource "aci_switch_association" "fooswitch_association" { + resource "aci_leaf_selector" "fooswitch_association" { leaf_profile_dn = "${aci_leaf_profile.example.id}" description = "%s" - + name = "example" - + switch_association_type = "example" annotation = "example" name_alias = "example" @@ -111,7 +111,7 @@ func testAccCheckAciSwitchAssociationDestroy(s *terraform.State) error { for _, rs := range s.RootModule().Resources { - if rs.Type == "aci_switch_association" { + if rs.Type == "aci_leaf_selector" { cont, err := client.Get(rs.Primary.ID) switch_association := models.SwitchAssociationFromContainer(cont) if err == nil { diff --git a/aci/resource_aci_infranodeblk_test.go b/aci/resource_aci_infranodeblk_test.go index 497b51aa6..c3cdbe43b 100644 --- a/aci/resource_aci_infranodeblk_test.go +++ b/aci/resource_aci_infranodeblk_test.go @@ -66,9 +66,9 @@ func testAccCheckAciInfraNodeBlockConfig_basic(description string) string { return fmt.Sprintf(` resource "aci_node_block" "foonode_block" { - switch_association_dn = "${aci_switch_association.example.id}" + switch_association_dn = "${aci_leaf_selector.example.id}" description = "%s" - + name = "example" annotation = "example" from_ = "105" diff --git a/website/aci.erb b/website/aci.erb index 21255fae6..2841d02b1 100644 --- a/website/aci.erb +++ b/website/aci.erb @@ -258,8 +258,8 @@ > aci_subnet - > - aci_switch_association + > + aci_leaf_selector > aci_taboo_contract @@ -549,8 +549,8 @@ > aci_subnet - > - aci_switch_association + > + aci_leaf_selector > aci_taboo_contract diff --git a/website/docs/d/infraleafs.html.markdown b/website/docs/d/infraleafs.html.markdown index eacdb366f..7467d778f 100644 --- a/website/docs/d/infraleafs.html.markdown +++ b/website/docs/d/infraleafs.html.markdown @@ -1,18 +1,18 @@ --- layout: "aci" -page_title: "ACI: aci_switch_association" -sidebar_current: "docs-aci-data-source-switch_association" +page_title: "ACI: aci_leaf_selector" +sidebar_current: "docs-aci-data-source-leaf_selector" description: |- - Data source for ACI Switch Association + Data source for ACI Leaf Selector --- -# aci_switch_association # -Data source for ACI Switch Association +# aci_leaf_selector # +Data source for ACI Leaf Selector ## Example Usage ## ```hcl -data "aci_switch_association" "example" { +data "aci_leaf_selector" "example" { leaf_profile_dn = "${aci_leaf_profile.example.id}" diff --git a/website/docs/d/infranodeblk.html.markdown b/website/docs/d/infranodeblk.html.markdown index b8ef28636..d1796e08c 100644 --- a/website/docs/d/infranodeblk.html.markdown +++ b/website/docs/d/infranodeblk.html.markdown @@ -13,7 +13,7 @@ Data source for ACI Node Block ```hcl data "aci_node_block" "example" { - switch_association_dn = "${aci_switch_association.example.id}" + switch_association_dn = "${aci_leaf_selector.example.id}" name = "example" } ``` diff --git a/website/docs/r/infraleafs.html.markdown b/website/docs/r/infraleafs.html.markdown index e6ca496b5..01fc97c9b 100644 --- a/website/docs/r/infraleafs.html.markdown +++ b/website/docs/r/infraleafs.html.markdown @@ -1,18 +1,18 @@ --- layout: "aci" -page_title: "ACI: aci_switch_association" -sidebar_current: "docs-aci-resource-switch_association" +page_title: "ACI: aci_leaf_selector" +sidebar_current: "docs-aci-resource-leaf_selector" description: |- - Manages ACI Switch Association + Manages ACI Leaf Selector --- -# aci_switch_association # -Manages ACI Switch Association +# aci_leaf_selector # +Manages ACI Leaf Selector ## Example Usage ## ```hcl -resource "aci_switch_association" "example" { +resource "aci_leaf_selector" "example" { leaf_profile_dn = "${aci_leaf_profile.example.id}" @@ -47,5 +47,5 @@ An existing Switch Association can be [imported][docs-import] into this resource ``` -terraform import aci_switch_association.example -``` \ No newline at end of file +terraform import aci_leaf_selector.example +``` diff --git a/website/docs/r/infranodeblk.html.markdown b/website/docs/r/infranodeblk.html.markdown index 7bb7af92a..3a1b1aa35 100644 --- a/website/docs/r/infranodeblk.html.markdown +++ b/website/docs/r/infranodeblk.html.markdown @@ -13,7 +13,7 @@ Manages ACI Node Block ```hcl resource "aci_node_block" "check" { - switch_association_dn = "${aci_switch_association.example.id}" + switch_association_dn = "${aci_leaf_selector.example.id}" name = "block" annotation = "aci_node_block" from_ = "105" @@ -44,4 +44,4 @@ An existing Node Block can be [imported][docs-import] into this resource via its ``` terraform import aci_node_block.example -``` \ No newline at end of file +```