@Override
    public boolean isValid(ParameterValue value) {
        return choices.contains(((StringParameterValue) value).getValue());
    }
@Test
    @Issue("JENKINS-62889")
    public void checkValue_WrongValueType() {
        String stringValue = "single";
        String[] choices = new String[]{stringValue};
        ChoiceParameterDefinition parameterDefinition = new ChoiceParameterDefinition("name", choices, "description");
        BooleanParameterValue parameterValue = new BooleanParameterValue("choice", false);
        assertThrows(ClassCastException.class, () -> parameterDefinition.isValid(parameterValue));
    }