Program: 136758
Project: 136758
Buggy source:
@Test public void testHandle(){
  InputStream in=null;
  try {
    in=new FileInputStream(new File("String_Node_Str"));
  }
 catch (  FileNotFoundException e1) {
    e1.printStackTrace();
  }
  BufferedReader inBuffReader=new BufferedReader(new InputStreamReader(in));
  String start="String_Node_Str";
  String end="String_Node_Str";
  String line=null;
  try {
    start=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + start);
    boolean isFirstLine=true;
    while ((line=inBuffReader.readLine()) != null) {
      String[] record=StringUtils.splitByWholeSeparatorPreserveAllTokens(line,"String_Node_Str");
      if (isFirstLine) {
        isFirstLine=false;
        semanticInferExecutor.init(record);
      }
      semanticInferExecutor.handle(record);
    }
    end=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + end);
    double timeDiff=TypeInferenceUtilsTest.getTimeDifference(start,end);
    printline("String_Node_Str" + timeDiff);
    Assert.assertTrue(timeDiff < 6);
    List<ColumnTypeBean> semanticTypeList=semanticInferExecutor.getResults();
    for (    ColumnTypeBean bean : semanticTypeList) {
      if (bean.getColumnIdx() == 1) {
        Map<String,Long> semanticTypeToCount=bean.getSemanticNameToCountMap();
        Iterator<String> semanticTypes=semanticTypeToCount.keySet().iterator();
        while (semanticTypes.hasNext()) {
          String semanticName=semanticTypes.next();
          if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(2l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(3l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(1l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(1l,semanticTypeToCount.get(semanticName),0l);
          }
        }
      }
 else       if (bean.getColumnIdx() == 10) {
        Assert.assertEquals("String_Node_Str",bean.getSemanticNameToCountMap().keySet().toArray()[0].toString());
        Assert.assertEquals(1000,bean.getSemanticTypeCount("String_Node_Str"),0);
      }
    }
    try {
      in=new FileInputStream(new File("String_Node_Str"));
    }
 catch (    FileNotFoundException e1) {
      e1.printStackTrace();
    }
    inBuffReader=new BufferedReader(new InputStreamReader(in));
    start="String_Node_Str";
    end="String_Node_Str";
    line=null;
    start=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + start);
    isFirstLine=true;
    while ((line=inBuffReader.readLine()) != null) {
      String[] record=StringUtils.splitByWholeSeparatorPreserveAllTokens(line,"String_Node_Str");
      if (isFirstLine) {
        isFirstLine=false;
        semanticInferExecutor.init(record);
      }
      semanticInferExecutor.handle(record);
    }
    end=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + end);
    timeDiff=TypeInferenceUtilsTest.getTimeDifference(start,end);
    printline("String_Node_Str" + timeDiff);
    Assert.assertTrue(timeDiff < 8);
    semanticTypeList=semanticInferExecutor.getResults();
    for (    ColumnTypeBean bean : semanticTypeList) {
      if (bean.getColumnIdx() == 1) {
        Map<String,Long> semanticTypeToCount=bean.getSemanticNameToCountMap();
        Iterator<String> semanticTypes=semanticTypeToCount.keySet().iterator();
        while (semanticTypes.hasNext()) {
          String semanticName=semanticTypes.next();
          if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(20l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(30l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(10l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(10l,semanticTypeToCount.get(semanticName),0l);
          }
        }
      }
 else       if (bean.getColumnIdx() == 10) {
        Assert.assertEquals("String_Node_Str",bean.getSemanticNameToCountMap().keySet().toArray()[0].toString());
        Assert.assertEquals(10000,bean.getSemanticTypeCount("String_Node_Str"),0);
      }
    }
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}

Fixed version (ground truth):
@Test public void testHandle(){
  InputStream in=this.getClass().getClassLoader().getResourceAsStream("String_Node_Str");
  BufferedReader inBuffReader=new BufferedReader(new InputStreamReader(in));
  String start="String_Node_Str";
  String end="String_Node_Str";
  String line=null;
  try {
    start=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + start);
    boolean isFirstLine=true;
    while ((line=inBuffReader.readLine()) != null) {
      String[] record=StringUtils.splitByWholeSeparatorPreserveAllTokens(line,"String_Node_Str");
      if (isFirstLine) {
        isFirstLine=false;
        semanticInferExecutor.init(record);
      }
      semanticInferExecutor.handle(record);
    }
    end=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + end);
    double timeDiff=TypeInferenceUtilsTest.getTimeDifference(start,end);
    printline("String_Node_Str" + timeDiff);
    Assert.assertTrue(timeDiff < 7);
    List<ColumnTypeBean> semanticTypeList=semanticInferExecutor.getResults();
    for (    ColumnTypeBean bean : semanticTypeList) {
      if (bean.getColumnIdx() == 1) {
        Map<String,Long> semanticTypeToCount=bean.getSemanticNameToCountMap();
        Iterator<String> semanticTypes=semanticTypeToCount.keySet().iterator();
        while (semanticTypes.hasNext()) {
          String semanticName=semanticTypes.next();
          if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(2l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(3l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(1l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(1l,semanticTypeToCount.get(semanticName),0l);
          }
        }
      }
 else       if (bean.getColumnIdx() == 10) {
        Assert.assertEquals("String_Node_Str",bean.getSemanticNameToCountMap().keySet().toArray()[0].toString());
        Assert.assertEquals(1000,bean.getSemanticTypeCount("String_Node_Str"),0);
      }
    }
    in=this.getClass().getClassLoader().getResourceAsStream("String_Node_Str");
    inBuffReader=new BufferedReader(new InputStreamReader(in));
    start="String_Node_Str";
    end="String_Node_Str";
    line=null;
    start=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + start);
    isFirstLine=true;
    while ((line=inBuffReader.readLine()) != null) {
      String[] record=StringUtils.splitByWholeSeparatorPreserveAllTokens(line,"String_Node_Str");
      if (isFirstLine) {
        isFirstLine=false;
        semanticInferExecutor.init(record);
      }
      semanticInferExecutor.handle(record);
    }
    end=TypeInferenceUtilsTest.getCurrentTimeStamp();
    printline("String_Node_Str" + end);
    timeDiff=TypeInferenceUtilsTest.getTimeDifference(start,end);
    printline("String_Node_Str" + timeDiff);
    Assert.assertTrue(timeDiff < 9);
    semanticTypeList=semanticInferExecutor.getResults();
    for (    ColumnTypeBean bean : semanticTypeList) {
      if (bean.getColumnIdx() == 1) {
        Map<String,Long> semanticTypeToCount=bean.getSemanticNameToCountMap();
        Iterator<String> semanticTypes=semanticTypeToCount.keySet().iterator();
        while (semanticTypes.hasNext()) {
          String semanticName=semanticTypes.next();
          if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(20l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(30l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(10l,semanticTypeToCount.get(semanticName),0l);
          }
 else           if ("String_Node_Str".equalsIgnoreCase(semanticName)) {
            Assert.assertEquals(10l,semanticTypeToCount.get(semanticName),0l);
          }
        }
      }
 else       if (bean.getColumnIdx() == 10) {
        Assert.assertEquals("String_Node_Str",bean.getSemanticNameToCountMap().keySet().toArray()[0].toString());
        Assert.assertEquals(10000,bean.getSemanticTypeCount("String_Node_Str"),0);
      }
    }
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}