private Input createInput(int result) throws IOException
    {
        Input input = Mockito.mock(Input.class);
        Mockito.when(input.readFieldNumber(Mockito.any(Schema.class)))
                .thenReturn(1)
                .thenReturn(0);
        Mockito.when(input.readInt32())
                .thenReturn(result);
        return input;
    }
Test that generated #mergeFrom method can be used multiple times

@throws Exception
protostuff-it/src/test/java/io/protostuff/compiler/java_bean/RepeatedIT.java