Skip to content

Commit 9501c4e

Browse files
committed
[API] Clear Index Templates with delete_index_template
1 parent 575115e commit 9501c4e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

api-spec-testing/test_file.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,10 @@ def clear_machine_learning_indices(client)
178178

179179
def clear_index_templates(client)
180180
client.indices.delete_template(name: '*')
181+
templates = client.indices.get_index_template
182+
templates['index_templates'].each do |template|
183+
client.indices.delete_index_template(name: template['name'])
184+
end
181185
end
182186

183187
def clear_snapshots_and_repositories(client)

0 commit comments

Comments
 (0)