File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed
server/src/test/java/org/elasticsearch/cluster/metadata Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -330,7 +330,6 @@ public void testEffectiveRetention() {
330330 DataStreamLifecycle noFailuresRetentionLifecycle = DataStreamLifecycle .failuresLifecycleBuilder ().build ();
331331 TimeValue maxRetention = TimeValue .timeValueDays (randomIntBetween (50 , 100 ));
332332 TimeValue defaultRetention = TimeValue .timeValueDays (randomIntBetween (1 , 50 ));
333- TimeValue failuresDefaultRetention = TimeValue .timeValueDays (randomIntBetween (1 , 100 ));
334333
335334 // No global retention
336335 // Data lifecycle
@@ -372,13 +371,8 @@ public void testEffectiveRetention() {
372371 new DataStreamGlobalRetention (defaultRetention , maxRetention ),
373372 false
374373 );
375- if (maxRetention .getMillis () < failuresDefaultRetention .getMillis ()) {
376- assertThat (effectiveFailuresRetentionWithSource .v1 (), equalTo (maxRetention ));
377- assertThat (effectiveFailuresRetentionWithSource .v2 (), equalTo (MAX_GLOBAL_RETENTION ));
378- } else {
379- assertThat (effectiveFailuresRetentionWithSource .v1 (), equalTo (failuresDefaultRetention ));
380- assertThat (effectiveFailuresRetentionWithSource .v2 (), equalTo (DEFAULT_GLOBAL_RETENTION ));
381- }
374+ assertThat (effectiveFailuresRetentionWithSource .v1 (), equalTo (defaultRetention ));
375+ assertThat (effectiveFailuresRetentionWithSource .v2 (), equalTo (DEFAULT_GLOBAL_RETENTION ));
382376 }
383377
384378 // With retention in the data stream lifecycle
You can’t perform that action at this time.
0 commit comments