public static void getSemanticPropsDualFromString(
            DualInputSemanticProperties result,
            String[] forwardedFirst,
            String[] forwardedSecond,
            String[] nonForwardedFirst,
            String[] nonForwardedSecond,
            String[] readFieldsFirst,
            String[] readFieldsSecond,
            TypeInformation<?> inType1,
            TypeInformation<?> inType2,
            TypeInformation<?> outType) {
        getSemanticPropsDualFromString(
                result,
                forwardedFirst,
                forwardedSecond,
                nonForwardedFirst,
                nonForwardedSecond,
                readFieldsFirst,
                readFieldsSecond,
                inType1,
                inType2,
                outType,
                false);
    }
@Test
    void testNonForwardedDual() {
        String[] nonForwardedFieldsFirst = {"f1;f2"};
        String[] nonForwardedFieldsSecond = {"f0"};
        DualInputSemanticProperties dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                nonForwardedFieldsFirst,
                nonForwardedFieldsSecond,
                null,
                null,
                threeIntTupleType,
                threeIntTupleType,
                threeIntTupleType);

        assertThat(dsp.getForwardingTargetFields(0, 0)).contains(0);
        assertThat(dsp.getForwardingTargetFields(0, 1)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(0, 2)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 0)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 1)).contains(1);
        assertThat(dsp.getForwardingTargetFields(1, 2)).contains(2);

        nonForwardedFieldsFirst[0] = "f1";
        nonForwardedFieldsSecond[0] = "";
        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                nonForwardedFieldsFirst,
                null,
                null,
                null,
                threeIntTupleType,
                fiveIntTupleType,
                threeIntTupleType);

        assertThat(dsp.getForwardingTargetFields(0, 0)).contains(0);
        assertThat(dsp.getForwardingTargetFields(0, 1)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(0, 2)).contains(2);
        assertThat(dsp.getForwardingTargetFields(1, 0)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 1)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 2)).isEmpty();

        nonForwardedFieldsFirst[0] = "";
        nonForwardedFieldsSecond[0] = "f2;f0";
        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                null,
                nonForwardedFieldsSecond,
                null,
                null,
                fiveIntTupleType,
                threeIntTupleType,
                threeIntTupleType);

        assertThat(dsp.getForwardingTargetFields(0, 0)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(0, 1)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(0, 2)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 0)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 1)).contains(1);
        assertThat(dsp.getForwardingTargetFields(1, 2)).isEmpty();

        String[] nonForwardedFields = {"f1", "f3"};
        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                nonForwardedFields,
                null,
                null,
                null,
                fiveIntTupleType,
                threeIntTupleType,
                fiveIntTupleType);

        assertThat(dsp.getForwardingTargetFields(0, 0)).contains(0);
        assertThat(dsp.getForwardingTargetFields(0, 1)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(0, 2)).contains(2);
        assertThat(dsp.getForwardingTargetFields(0, 3)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(0, 4)).contains(4);

        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                null,
                nonForwardedFields,
                null,
                null,
                threeIntTupleType,
                fiveIntTupleType,
                fiveIntTupleType);

        assertThat(dsp.getForwardingTargetFields(1, 0)).contains(0);
        assertThat(dsp.getForwardingTargetFields(1, 1)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 2)).contains(2);
        assertThat(dsp.getForwardingTargetFields(1, 3)).isEmpty();
        assertThat(dsp.getForwardingTargetFields(1, 4)).contains(4);
    }