static void valueMustBeValid(EvaluationContext ctx, Object value) {
        if (!(value instanceof BigDecimal) && !(value instanceof LocalDate)) {
            ctx.notifyEvt(() -> new ASTEventBase(FEELEvent.Severity.ERROR, Msg.createMessage(Msg.VALUE_X_NOT_A_VALID_ENDPOINT_FOR_RANGE_BECAUSE_NOT_A_NUMBER_NOT_A_DATE, value), null));
            throw new EndpointOfRangeNotValidTypeException();
        }
    }
@Test
    void valueMustBeValidFalseTest() {
        try {
            valueMustBeValid(ctx, "INVALID");
        } catch (Exception e) {
            assertTrue(e instanceof EndpointOfRangeNotValidTypeException);
            final ArgumentCaptor<FEELEvent> captor = ArgumentCaptor.forClass(FEELEvent.class);
            verify(listener, times(1)).onEvent(captor.capture());
        }
    }