Program: 29102
Project: 29102
Buggy source:
@Test public void testCreateFromXMLFunctionExtension2() throws InterruptedException {
  log.info("String_Node_Str");
  SiddhiManager siddhiManager=new SiddhiManager();
  siddhiManager.setExtension("String_Node_Str",ConcatFunctionExtension.class);
  String inStreamDefinition="String_Node_Str";
  String query=("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str");
  ExecutionPlanRuntime executionPlanRuntime=siddhiManager.createExecutionPlanRuntime(inStreamDefinition + query);
  executionPlanRuntime.addCallback("String_Node_Str",new StreamCallback(){
    @Override public void receive(    Event[] inEvents){
      EventPrinter.print(inEvents);
      for (      Event event : inEvents) {
        count.incrementAndGet();
        if (count.get() == 1) {
          Assert.assertEquals("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str",event.getData(0));
          eventArrived=true;
        }
        if (count.get() == 2) {
          Assert.assertEquals("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str",event.getData(0));
          eventArrived=true;
        }
        if (count.get() == 3) {
          Assert.assertEquals("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str",event.getData(0));
          eventArrived=true;
        }
      }
    }
  }
);
  InputHandler inputHandler=executionPlanRuntime.getInputHandler("String_Node_Str");
  executionPlanRuntime.start();
  inputHandler.send(new Object[]{25,100.1,true,"String_Node_Str"});
  inputHandler.send(new Object[]{35,100.11,false,"String_Node_Str"});
  inputHandler.send(new Object[]{45,100.13456,true,"String_Node_Str"});
  SiddhiTestHelper.waitForEvents(100,3,count,60000);
  Assert.assertEquals(3,count.get());
  Assert.assertTrue(eventArrived);
  executionPlanRuntime.shutdown();
}

Fixed version (ground truth):
@Test public void testCreateFromXMLFunctionExtension2() throws InterruptedException {
  log.info("String_Node_Str");
  SiddhiManager siddhiManager=new SiddhiManager();
  siddhiManager.setExtension("String_Node_Str",ConcatFunctionExtension.class);
  String inStreamDefinition="String_Node_Str";
  String query=("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str");
  ExecutionPlanRuntime executionPlanRuntime=siddhiManager.createExecutionPlanRuntime(inStreamDefinition + query);
  executionPlanRuntime.addCallback("String_Node_Str",new StreamCallback(){
    @Override public void receive(    Event[] inEvents){
      EventPrinter.print(inEvents);
      for (      Event event : inEvents) {
        count.incrementAndGet();
        if (count.get() == 1) {
          try {
            Assert.assertEquals(true,new XMLComparator().compare(AXIOMUtil.stringToOM("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"),AXIOMUtil.stringToOM((String)event.getData(0))));
          }
 catch (          XMLComparisonException e) {
            log.error("String_Node_Str" + e.getMessage(),e);
          }
catch (          XMLStreamException e) {
            log.error("String_Node_Str" + e.getMessage(),e);
          }
          eventArrived=true;
        }
        if (count.get() == 2) {
          try {
            Assert.assertEquals(true,new XMLComparator().compare(AXIOMUtil.stringToOM("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"),AXIOMUtil.stringToOM((String)event.getData(0))));
          }
 catch (          XMLComparisonException e) {
            log.error("String_Node_Str" + e.getMessage(),e);
          }
catch (          XMLStreamException e) {
            log.error("String_Node_Str" + e.getMessage(),e);
          }
          eventArrived=true;
        }
        if (count.get() == 3) {
          try {
            Assert.assertEquals(true,new XMLComparator().compare(AXIOMUtil.stringToOM("String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"),AXIOMUtil.stringToOM((String)event.getData(0))));
          }
 catch (          XMLComparisonException e) {
            log.error("String_Node_Str" + e.getMessage(),e);
          }
catch (          XMLStreamException e) {
            log.error("String_Node_Str" + e.getMessage(),e);
          }
          eventArrived=true;
        }
      }
    }
  }
);
  InputHandler inputHandler=executionPlanRuntime.getInputHandler("String_Node_Str");
  executionPlanRuntime.start();
  inputHandler.send(new Object[]{25,100.1,true,"String_Node_Str"});
  inputHandler.send(new Object[]{35,100.11,false,"String_Node_Str"});
  inputHandler.send(new Object[]{45,100.13456,true,"String_Node_Str"});
  SiddhiTestHelper.waitForEvents(100,3,count,60000);
  Assert.assertEquals(3,count.get());
  Assert.assertTrue(eventArrived);
  executionPlanRuntime.shutdown();
}