The following ILM tests all contain switch statements with branches that will never execute. The tests use a `between(x, y)` switch expression, but there are `case` values that are outside the randomised range. We need to fix these before #88739 can be merged. By "fix", I mean either remove the spurious cases, or if we actually want them, then extend the randomized range.

   * ActionConfigStatsTests
   * AllocateActionTests
   * CopyExecutionStateStepTests
   * RolloverActionTests
   * WaitForRolloverReadyStepTests

x-pack/plugin/core/src/test/java/org/elasticsearch/xpack/core/ilm/RolloverActionTests.java
UpdateSettingsStep fifthStep = (UpdateSettingsStep) steps.get(4);
        assertEquals(expectedFirstStepKey, firstStep.getKey());
        assertEquals(expectedSecondStepKey, secondStep.getKey());
        assertEquals(expectedThirdStepKey, thirdStep.getKey());
        assertEquals(expectedFourthStepKey, fourthStep.getKey());
        assertEquals(expectedFifthStepKey, fifthStep.getKey());
        assertEquals(secondStep.getKey(), firstStep.getNextStepKey());
        assertEquals(thirdStep.getKey(), secondStep.getNextStepKey());
        assertEquals(fourthStep.getKey(), thirdStep.getNextStepKey());
        assertEquals(fifthStep.getKey(), fourthStep.getNextStepKey());
        assertEquals(action.getMaxSize(), firstStep.getMaxSize());
        assertEquals(action.getMaxPrimaryShardSize(), firstStep.getMaxPrimaryShardSize());
        assertEquals(action.getMaxAge(), firstStep.getMaxAge());
        assertEquals(action.getMaxDocs(), firstStep.getMaxDocs());
        assertEquals(action.getMaxPrimaryShardDocs(), firstStep.getMaxPrimaryShardDocs());
        assertEquals(nextStepKey, fifthStep.getNextStepKey());
    }
    public void testBwcSerializationWithMaxPrimaryShardDocs() throws Exception {
        
        RolloverAction instance = new RolloverAction(null, null, null, null, 1L);
        RolloverAction deserializedInstance = copyInstance(instance, Version.V_8_1_0);
        assertThat(deserializedInstance.getMaxPrimaryShardDocs(), nullValue());
        
        instance = new RolloverAction(null, null, null, 2L, 1L);
        deserializedInstance = copyInstance(instance, Version.V_8_1_0);
        assertThat(deserializedInstance.getMaxPrimaryShardDocs(), nullValue());
        assertThat(deserializedInstance.getMaxDocs(), equalTo(instance.getMaxDocs()));
    }
}