fix state left over by spec test
@@ -101,3 +101,19 @@ setup:
lifecycle: "my_timeseries_lifecycle"
- match: { error.root_cause.0.type: "illegal_argument_exception" }
- match: { error.root_cause.0.reason: "Cannot delete policy [my_timeseries_lifecycle]. It is being used by at least one index [my_timeseries_index]" }
+
+ - do:
+ indices.put_settings:
+ index: my_timeseries_index
+ body:
+ index.lifecycle.name: ""
+
+ - do:
+ acknowledge: true
+ xpack.index_lifecycle.delete_lifecycle:
+ lifecycle: "my_timeseries_lifecycle"
+
+ - do:
+ catch: missing
+ xpack.index_lifecycle.get_lifecycle:
+ lifecycle: "my_timeseries_lifecycle"
