diff --git a/azurerm/data_source_api_management_product.go b/azurerm/data_source_api_management_product.go index abddc0d43ebe..a88446a9f287 100644 --- a/azurerm/data_source_api_management_product.go +++ b/azurerm/data_source_api_management_product.go @@ -62,7 +62,7 @@ func dataSourceApiManagementProductRead(d *schema.ResourceData, meta interface{} ctx := meta.(*ArmClient).StopContext resourceGroup := d.Get("resource_group_name").(string) - serviceName := d.Get("service_name").(string) + serviceName := d.Get("api_management_name").(string) productId := d.Get("product_id").(string) resp, err := client.Get(ctx, resourceGroup, serviceName, productId) diff --git a/azurerm/resource_arm_api_management_product_test.go b/azurerm/resource_arm_api_management_product_test.go index 11d19e22fb25..cc6d17767a3f 100644 --- a/azurerm/resource_arm_api_management_product_test.go +++ b/azurerm/resource_arm_api_management_product_test.go @@ -130,7 +130,7 @@ func TestAccAzureRMApiManagementProduct_update(t *testing.T) { Config: testAccAzureRMApiManagementProduct_updated(ri, location), Check: resource.ComposeTestCheckFunc( testCheckAzureRMApiManagementProductExists(resourceName), - resource.TestCheckResourceAttr(resourceName, "approval_required", "true"), + resource.TestCheckResourceAttr(resourceName, "approval_required", "false"), resource.TestCheckResourceAttr(resourceName, "description", ""), resource.TestCheckResourceAttr(resourceName, "display_name", "Test Updated Product"), resource.TestCheckResourceAttr(resourceName, "product_id", "test-product"),