Program: 76916
Project: 76916
Buggy source:
public void testPropertiesOfDynamicParameter() throws Exception {
  SlotHandle params=designHandle.getParameters();
  ScalarParameterHandle handle=(ScalarParameterHandle)params.get(0);
  SlotHandle dataset=designHandle.getDataSets();
  DataSetHandle ds=(DataSetHandle)dataset.get(0);
  assertEquals("String_Node_Str",ds.getName());
  assertEquals("String_Node_Str",dataset.get(1).getName());
  assertEquals(DesignChoiceConstants.PARAM_VALUE_TYPE_DYNAMIC,handle.getValueType());
  assertEquals(DesignChoiceConstants.PARAM_TYPE_DATETIME,handle.getDataType());
  handle.setPromptText("String_Node_Str");
  assertEquals("String_Node_Str",handle.getPromptText());
  handle.setDataSetName("String_Node_Str");
  handle.setValueExpr("String_Node_Str");
  assertEquals("String_Node_Str",handle.getValueExpr());
  handle.setControlType(DesignChoiceConstants.PARAM_CONTROL_LIST_BOX);
  assertEquals(DesignChoiceConstants.PARAM_CONTROL_LIST_BOX,handle.getControlType());
  handle.setDefaultValue("String_Node_Str");
  assertEquals("String_Node_Str",handle.getDefaultValue());
  handle.setCategory(DesignChoiceConstants.DATETIEM_FORMAT_TYPE_LONG_DATE);
  assertEquals(DesignChoiceConstants.DATETIEM_FORMAT_TYPE_LONG_DATE,handle.getCategory());
  handle.setListlimit(20);
  assertEquals(20,handle.getListlimit());
  assertTrue(handle.isMustMatch());
  assertTrue(handle.isFixedOrder());
  handle=(ScalarParameterHandle)params.get(1);
  assertEquals(DesignChoiceConstants.PARAM_VALUE_TYPE_DYNAMIC,handle.getValueType());
  assertEquals(DesignChoiceConstants.PARAM_TYPE_FLOAT,handle.getDataType());
  handle.setDataSetName("String_Node_Str");
  handle.setValueExpr("String_Node_Str");
  assertEquals("String_Node_Str",handle.getValueExpr());
  assertEquals(DesignChoiceConstants.PARAM_CONTROL_LIST_BOX,handle.getControlType());
  assertFalse(handle.isHidden());
  assertEquals("String_Node_Str",handle.getHelpText());
  assertFalse(handle.isConcealValue());
  assertFalse(handle.allowBlank());
  assertTrue(handle.allowNull());
  assertEquals(DesignChoiceConstants.SCALAR_PARAM_ALIGN_LEFT,handle.getAlignment());
  assertEquals("String_Node_Str",handle.getPattern());
  assertEquals(5,handle.getListlimit());
  try {
    openDesign("String_Node_Str");
  }
 catch (  DesignFileException e) {
  }
  super.saveAs(OUTPUT_FILE_NAME);
  assertTrue(compareTextFile(GOLDEN_FILE_NAME,OUTPUT_FILE_NAME));
}

Fixed version (ground truth):
public void testPropertiesOfDynamicParameter() throws Exception {
  SlotHandle params=designHandle.getParameters();
  ScalarParameterHandle handle=(ScalarParameterHandle)params.get(0);
  SlotHandle dataset=designHandle.getDataSets();
  DataSetHandle ds=(DataSetHandle)dataset.get(0);
  assertEquals("String_Node_Str",ds.getName());
  assertEquals("String_Node_Str",dataset.get(1).getName());
  assertEquals(DesignChoiceConstants.PARAM_VALUE_TYPE_DYNAMIC,handle.getValueType());
  assertEquals(DesignChoiceConstants.PARAM_TYPE_DATETIME,handle.getDataType());
  handle.setPromptText("String_Node_Str");
  assertEquals("String_Node_Str",handle.getPromptText());
  handle.setDataSetName("String_Node_Str");
  handle.setValueExpr("String_Node_Str");
  assertEquals("String_Node_Str",handle.getValueExpr());
  handle.setControlType(DesignChoiceConstants.PARAM_CONTROL_LIST_BOX);
  assertEquals(DesignChoiceConstants.PARAM_CONTROL_LIST_BOX,handle.getControlType());
  handle.setDefaultValue("String_Node_Str");
  assertEquals("String_Node_Str",handle.getDefaultValue());
  handle.setCategory(DesignChoiceConstants.DATETIEM_FORMAT_TYPE_LONG_DATE);
  assertEquals(DesignChoiceConstants.DATETIEM_FORMAT_TYPE_LONG_DATE,handle.getCategory());
  handle.setListlimit(20);
  assertEquals(20,handle.getListlimit());
  assertFalse(handle.isMustMatch());
  assertTrue(handle.isFixedOrder());
  handle=(ScalarParameterHandle)params.get(1);
  assertEquals(DesignChoiceConstants.PARAM_VALUE_TYPE_DYNAMIC,handle.getValueType());
  assertEquals(DesignChoiceConstants.PARAM_TYPE_FLOAT,handle.getDataType());
  handle.setDataSetName("String_Node_Str");
  handle.setValueExpr("String_Node_Str");
  assertEquals("String_Node_Str",handle.getValueExpr());
  assertEquals(DesignChoiceConstants.PARAM_CONTROL_LIST_BOX,handle.getControlType());
  assertFalse(handle.isHidden());
  assertEquals("String_Node_Str",handle.getHelpText());
  assertFalse(handle.isConcealValue());
  assertFalse(handle.allowBlank());
  assertTrue(handle.allowNull());
  assertEquals(DesignChoiceConstants.SCALAR_PARAM_ALIGN_LEFT,handle.getAlignment());
  assertEquals("String_Node_Str",handle.getPattern());
  assertEquals(5,handle.getListlimit());
  try {
    openDesign("String_Node_Str");
  }
 catch (  DesignFileException e) {
  }
  super.saveAs(OUTPUT_FILE_NAME);
  assertTrue(compareTextFile(GOLDEN_FILE_NAME,OUTPUT_FILE_NAME));
}