Program: 64995
Project: 64995
Buggy source:
/** 
 * Tests Label element in the PageSetup and Body slots.
 * @throws Exception if opening design file failed.
 */
public void testParser() throws Exception {
  LabelHandle labelHandle=getLabel();
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.X_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.Y_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.HEIGHT_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.WIDTH_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.TEXT_PROP));
  OdaDataSet dataSet=(OdaDataSet)design.findDataSet("String_Node_Str");
  assertNotNull(dataSet);
  assertEquals(dataSet.getName(),labelHandle.getProperty(Label.DATA_SET_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.COLOR_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.FONT_FAMILY_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.FONT_SIZE_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.FONT_WEIGHT_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.TEXT_UNDERLINE_PROP));
  assertEquals(null,labelHandle.getStringProperty(Style.HIGHLIGHT_RULES_PROP));
  ActionHandle action=labelHandle.getActionHandle();
  assertNotNull(action);
  assertEquals(DesignChoiceConstants.ACTION_LINK_TYPE_HYPERLINK,action.getLinkType());
  assertEquals("String_Node_Str",action.getURI());
  assertEquals("String_Node_Str",labelHandle.getRole());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getCustomXml());
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.COLOR_PROP));
  assertEquals("String_Node_Str",labelHandle.getText());
  assertEquals("String_Node_Str",labelHandle.getHelpText());
  assertEquals("String_Node_Str",labelHandle.getHelpTextKey());
  assertEquals("String_Node_Str",labelHandle.getTextKey());
  assertEquals("String_Node_Str",labelHandle.getRole());
  assertEquals("String_Node_Str",labelHandle.getLanguage());
  assertEquals("String_Node_Str",labelHandle.getAltText());
  assertEquals(1,labelHandle.getOrder());
  assertEquals(ReportDesign.BODY_SLOT,labelHandle.getContainer().findContentSlot(labelHandle));
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  assertEquals("String_Node_Str",labelHandle.getHelpText());
  assertEquals("String_Node_Str",labelHandle.getHelpTextKey());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  assertTrue(labelHandle.pushDown());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  assertTrue(labelHandle.pushDown());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
}

Fixed version (ground truth):
/** 
 * Tests Label element in the PageSetup and Body slots.
 * @throws Exception if opening design file failed.
 */
public void testParser() throws Exception {
  LabelHandle labelHandle=getLabel();
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.X_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.Y_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.HEIGHT_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.WIDTH_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Label.TEXT_PROP));
  OdaDataSet dataSet=(OdaDataSet)design.findDataSet("String_Node_Str");
  assertNotNull(dataSet);
  assertEquals(dataSet.getName(),labelHandle.getProperty(Label.DATA_SET_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.COLOR_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.FONT_FAMILY_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.FONT_SIZE_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.FONT_WEIGHT_PROP));
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.TEXT_UNDERLINE_PROP));
  assertEquals(null,labelHandle.getStringProperty(Style.HIGHLIGHT_RULES_PROP));
  ActionHandle action=labelHandle.getActionHandle();
  assertNotNull(action);
  assertEquals(DesignChoiceConstants.ACTION_LINK_TYPE_HYPERLINK,action.getLinkType());
  assertEquals("String_Node_Str",action.getURI());
  assertEquals("String_Node_Str",labelHandle.getTagType());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getCustomXml());
  assertEquals("String_Node_Str",labelHandle.getStringProperty(Style.COLOR_PROP));
  assertEquals("String_Node_Str",labelHandle.getText());
  assertEquals("String_Node_Str",labelHandle.getHelpText());
  assertEquals("String_Node_Str",labelHandle.getHelpTextKey());
  assertEquals("String_Node_Str",labelHandle.getTextKey());
  assertEquals("String_Node_Str",labelHandle.getTagType());
  assertEquals("String_Node_Str",labelHandle.getLanguage());
  assertEquals("String_Node_Str",labelHandle.getAltText());
  assertEquals(1,labelHandle.getOrder());
  assertEquals(ReportDesign.BODY_SLOT,labelHandle.getContainer().findContentSlot(labelHandle));
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  assertEquals("String_Node_Str",labelHandle.getHelpText());
  assertEquals("String_Node_Str",labelHandle.getHelpTextKey());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  assertTrue(labelHandle.pushDown());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  assertTrue(labelHandle.pushDown());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
  labelHandle=(LabelHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",labelHandle.getText());
}