Skip to content

Commit

Permalink
ec_extension: set empty id when delete succeed
Browse files Browse the repository at this point in the history
  • Loading branch information
snowhork committed Jan 7, 2021
1 parent 1aa8c44 commit ecb300f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions ec/ecresource/extensionresource/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ func deleteResource(_ context.Context, d *schema.ResourceData, meta interface{})
return diag.FromErr(err)
}

d.SetId("")
return nil
}

Expand Down
1 change: 1 addition & 0 deletions ec/ecresource/extensionresource/delete_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ func Test_deleteResource(t *testing.T) {
State: newExtension(),
Schema: newSchema(),
})
wantTC200.SetId("")

tc500Err := util.NewResourceData(t, util.ResDataParams{
ID: "12345678",
Expand Down

0 comments on commit ecb300f

Please sign in to comment.