protected void commonDeclareOutputFields(final List<OutputField> outputFields, final Object result, final StringJoiner joiner) {
        outputFields.forEach(kiePMMLOutputField -> {
            if (ResultFeature.PREDICTED_VALUE.equals(kiePMMLOutputField.getResultFeature())) {
                joiner.add(String.format(ADD_PMML4_OUTPUT_FIELD, kiePMMLOutputField.getName(), result));
            }
        });
    }
@Test
    void commonDeclareOutputFields() {
        String outputFieldName = "OUTPUTFIELDNAME";
        Object result = "RESULT";
        OutputField outputField = new OutputField();
        outputField.setName(outputFieldName);
        outputField.setResultFeature(ResultFeature.PREDICTED_VALUE);
        List<OutputField> outputFields = Collections.singletonList(outputField);
        StringJoiner joiner = new StringJoiner("");
        KiePMMLDescrRhsFactory.factory(ruleBuilder).commonDeclareOutputFields(outputFields, result, joiner);
        String retrieved = joiner.toString();
        String expected = String.format(ADD_PMML4_OUTPUT_FIELD, outputFieldName, result);
        assertThat(retrieved).isEqualTo(expected);
    }