Skip to content

Commit

Permalink
change resource name to azurerm_healthbot.
Browse files Browse the repository at this point in the history
  • Loading branch information
Haiyuan Zhang authored and haiyuazhang committed Apr 20, 2021
1 parent ab96787 commit 1eb900f
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion azurerm/internal/services/bot/bot_healthbot_resource.go
Expand Up @@ -89,7 +89,7 @@ func resourceHealthbotServiceCreate(d *schema.ResourceData, meta interface{}) er
}
}
if !utils.ResponseWasNotFound(existing.Response) {
return tf.ImportAsExistsError("azurerm_bot_healthbot", id.ID())
return tf.ImportAsExistsError("azurerm_healthbot", id.ID())
}
}

Expand Down
22 changes: 11 additions & 11 deletions azurerm/internal/services/bot/bot_healthbot_resource_test.go
Expand Up @@ -17,7 +17,7 @@ import (
type HealthbotResource struct{}

func TestAccBotHealthbot_basic(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_bot_healthbot", "test")
data := acceptance.BuildTestData(t, "azurerm_healthbot", "test")
r := HealthbotResource{}
data.ResourceTest(t, r, []resource.TestStep{
{
Expand All @@ -31,7 +31,7 @@ func TestAccBotHealthbot_basic(t *testing.T) {
}

func TestAccBotHealthbot_requiresImport(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_bot_healthbot", "test")
data := acceptance.BuildTestData(t, "azurerm_healthbot", "test")
r := HealthbotResource{}
data.ResourceTest(t, r, []resource.TestStep{
{
Expand All @@ -45,7 +45,7 @@ func TestAccBotHealthbot_requiresImport(t *testing.T) {
}

func TestAccBotHealthbot_complete(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_bot_healthbot", "test")
data := acceptance.BuildTestData(t, "azurerm_healthbot", "test")
r := HealthbotResource{}
data.ResourceTest(t, r, []resource.TestStep{
{
Expand All @@ -59,7 +59,7 @@ func TestAccBotHealthbot_complete(t *testing.T) {
}

func TestAccBotHealthbot_update(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_bot_healthbot", "test")
data := acceptance.BuildTestData(t, "azurerm_healthbot", "test")
r := HealthbotResource{}
data.ResourceTest(t, r, []resource.TestStep{
{
Expand Down Expand Up @@ -118,7 +118,7 @@ func (r HealthbotResource) basic(data acceptance.TestData) string {
return fmt.Sprintf(`
%s
resource "azurerm_bot_healthbot" "test" {
resource "azurerm_healthbot" "test" {
name = "acctest-hb-%d"
resource_group_name = azurerm_resource_group.test.name
location = azurerm_resource_group.test.location
Expand All @@ -132,11 +132,11 @@ func (r HealthbotResource) requiresImport(data acceptance.TestData) string {
return fmt.Sprintf(`
%s
resource "azurerm_bot_healthbot" "import" {
name = azurerm_bot_healthbot.test.name
resource_group_name = azurerm_bot_healthbot.test.resource_group_name
location = azurerm_bot_healthbot.test.location
sku_name = azurerm_bot_healthbot.test.sku_name
resource "azurerm_healthbot" "import" {
name = azurerm_healthbot.test.name
resource_group_name = azurerm_healthbot.test.resource_group_name
location = azurerm_healthbot.test.location
sku_name = azurerm_healthbot.test.sku_name
}
`, config)
}
Expand All @@ -146,7 +146,7 @@ func (r HealthbotResource) complete(data acceptance.TestData) string {
return fmt.Sprintf(`
%s
resource "azurerm_bot_healthbot" "test" {
resource "azurerm_healthbot" "test" {
name = "acctest-hb-%d"
resource_group_name = azurerm_resource_group.test.name
location = azurerm_resource_group.test.location
Expand Down
2 changes: 1 addition & 1 deletion azurerm/internal/services/bot/registration.go
Expand Up @@ -32,7 +32,7 @@ func (r Registration) SupportedResources() map[string]*schema.Resource {
"azurerm_bot_channel_slack": resourceBotChannelSlack(),
"azurerm_bot_channels_registration": resourceBotChannelsRegistration(),
"azurerm_bot_connection": resourceArmBotConnection(),
"azurerm_bot_healthbot": resourceHealthbotService(),
"azurerm_healthbot": resourceHealthbotService(),
"azurerm_bot_web_app": resourceBotWebApp(),
}
}
@@ -1,12 +1,12 @@
---
subcategory: "Bot"
layout: "azurerm"
page_title: "Azure Resource Manager: azurerm_bot_healthbot"
page_title: "Azure Resource Manager: azurerm_healthbot"
description: |-
Manages a Healthbot Service.
---

# azurerm_healthbot_service
# azurerm_healthbot

Manages a Healthbot Service.

Expand All @@ -18,7 +18,7 @@ resource "azurerm_resource_group" "example" {
location = "West Europe"
}
resource "azurerm_healthbot_service" "example" {
resource "azurerm_healthbot" "example" {
name = "example-bot"
resource_group_name = azurerm_resource_group.example.name
location = azurerm_resource_group.example.location
Expand Down Expand Up @@ -70,5 +70,5 @@ The `timeouts` block allows you to specify [timeouts](https://www.terraform.io/d
Healthbot Service can be imported using the `resource id`, e.g.

```shell
terraform import azurerm_healthbot_service.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.HealthBot/healthBots/bot1
terraform import azurerm_healthbot.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.HealthBot/healthBots/bot1
```

0 comments on commit 1eb900f

Please sign in to comment.