Skip to content

Commit

Permalink
Merge pull request #20951 from liuwuliuyun/language_extensions_2
Browse files Browse the repository at this point in the history
`azurerm_kusto_cluster` - fixes `TestAccKustoCluster_languageExtensions`
  • Loading branch information
tombuildsstuff authored Mar 20, 2023
2 parents 1756133 + e064ee6 commit 25b75bd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 2 additions & 2 deletions internal/services/kusto/kusto_cluster_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ func resourceKustoCluster() *pluginsdk.Resource {
},

"language_extensions": {
Type: pluginsdk.TypeList,
Type: pluginsdk.TypeSet,
Optional: true,
Elem: &pluginsdk.Schema{
Type: pluginsdk.TypeString,
Expand Down Expand Up @@ -377,7 +377,7 @@ func resourceKustoClusterCreateUpdate(d *pluginsdk.ResourceData, meta interface{
d.SetId(id.ID())

if v, ok := d.GetOk("language_extensions"); ok {
languageExtensions := expandKustoClusterLanguageExtensions(v.([]interface{}))
languageExtensions := expandKustoClusterLanguageExtensions(v.(*pluginsdk.Set).List())

currentLanguageExtensions, err := client.ListLanguageExtensions(ctx, id)
if err != nil {
Expand Down
2 changes: 0 additions & 2 deletions internal/services/kusto/kusto_cluster_resource_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -251,8 +251,6 @@ func TestAccKustoCluster_languageExtensions(t *testing.T) {
Check: acceptance.ComposeTestCheckFunc(
check.That(data.ResourceName).ExistsInAzure(r),
check.That(data.ResourceName).Key("language_extensions.#").HasValue("2"),
check.That(data.ResourceName).Key("language_extensions.0").HasValue("PYTHON"),
check.That(data.ResourceName).Key("language_extensions.1").HasValue("R"),
),
},
data.ImportStep(),
Expand Down

0 comments on commit 25b75bd

Please sign in to comment.