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 testReadFieldsDual() {
        String[] readFieldsFirst = {"f1;f2"};
        String[] readFieldsSecond = {"f0"};
        DualInputSemanticProperties dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                null,
                null,
                readFieldsFirst,
                readFieldsSecond,
                threeIntTupleType,
                threeIntTupleType,
                threeIntTupleType);

        assertThat(dsp.getReadFields(0)).containsExactly(1, 2);
        assertThat(dsp.getReadFields(1)).containsExactly(0);

        readFieldsFirst[0] = "f0.*; f2";
        readFieldsSecond[0] = "int1; string1";
        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                null,
                null,
                readFieldsFirst,
                readFieldsSecond,
                nestedTupleType,
                pojoType,
                threeIntTupleType);

        assertThat(dsp.getReadFields(0)).containsExactly(0, 1, 2, 4);
        assertThat(dsp.getReadFields(1)).containsExactly(0, 3);

        readFieldsFirst[0] = "pojo1.int2; string1";
        readFieldsSecond[0] = "f2.int2";
        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                null,
                null,
                readFieldsFirst,
                readFieldsSecond,
                nestedPojoType,
                pojoInTupleType,
                threeIntTupleType);

        assertThat(dsp.getReadFields(0)).hasSize(2).contains(2, 5);
        assertThat(dsp.getReadFields(1)).containsExactly(3);

        String[] readFields = {"f0", "f2", "f4"};
        dsp = new DualInputSemanticProperties();
        SemanticPropUtil.getSemanticPropsDualFromString(
                dsp,
                null,
                null,
                null,
                null,
                readFields,
                readFields,
                fiveIntTupleType,
                fiveIntTupleType,
                threeIntTupleType);

        assertThat(dsp.getReadFields(0)).containsExactly(0, 2, 4);
        assertThat(dsp.getReadFields(1)).containsExactly(0, 2, 4);
    }