nus-yam/ex-repair huggingface dataset:
Program: 67156
Project: 67156
Buggy source:
/** 
 * Tests override via eclipselink-oxm.xml.  Here, the metadata files are not handed in via properties or context path, but looked up by package in the context factory.  Various overrides will be performed to ensure  the xml files were picked up properly. 2 x Positive tests, 1x Negative test
 */
public void testLoadMultipleXmlFilesViaDifferentPackage(){
  outputResolver=generateSchema(new Class[]{Employee.class,Address.class},1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
  src=PATH + "String_Node_Str";
  result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
  src=PATH + "String_Node_Str";
  result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests override via eclipselink-oxm.xml.  Here, the metadata files are not handed in via properties or context path, but looked up by package in the context factory.  Various overrides will be performed to ensure  the xml files were picked up properly. 2 x Positive tests, 1x Negative test
 */
public void testLoadMultipleXmlFilesViaDifferentPackage(){
  outputResolver=generateSchema(new Class[]{Employee.class,Address.class},CONTEXT_PATH,PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
  src=PATH + "String_Node_Str";
  result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
  src=PATH + "String_Node_Str";
  result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67157
Project: 67157
Buggy source:
/** 
 * Tests @XmlAccessorOrder override via eclipselink-oxm.xml.  The Employee object has the order set to 'UNDEFINED', but this is overridden in the metadata xml file - 'ALPHABETICAL'. Negative test.
 */
public void testXmlAccessorOrderOverrideInvalidDoc(){
  outputResolver=generateSchema(CONTEXT_PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlAccessorOrder override via eclipselink-oxm.xml.  The Employee object has the order set to 'UNDEFINED', but this is overridden in the metadata xml file - 'ALPHABETICAL'. Negative test.
 */
public void testXmlAccessorOrderOverrideInvalidDoc(){
  outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67158
Project: 67158
Buggy source:
/** 
 * Tests @XmlAccessorOrder override via eclipselink-oxm.xml.  The Employee object has the order set to 'UNDEFINED', but this is overridden in the metadata xml file - 'ALPHABETICAL'. Positive test.
 */
public void testXmlAccessorOrderOverride(){
  outputResolver=generateSchema(CONTEXT_PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlAccessorOrder override via eclipselink-oxm.xml.  The Employee object has the order set to 'UNDEFINED', but this is overridden in the metadata xml file - 'ALPHABETICAL'. Positive test.
 */
public void testXmlAccessorOrderOverride(){
  outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67159
Project: 67159
Buggy source:
/** 
 * Tests no @XmlAccessorType override via eclipselink-oxm.xml. Positive test.
 */
public void testNoXmlAccessorTypeOverride(){
  outputResolver=generateSchema(CONTEXT_PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests no @XmlAccessorType override via eclipselink-oxm.xml. Positive test.
 */
public void testNoXmlAccessorTypeOverride(){
  outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67163
Project: 67163
Buggy source:
/** 
 * Tests @XmlAttribute override via eclipselink-oxm.xml.  The id attribute is set to 'required' in the xml file, but the instance document does not have an id attribute. Negative test.
 */
public void testXmlAttributeOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlAttribute override via eclipselink-oxm.xml.  The id attribute is set to 'required' in the xml file, but the instance document does not have an id attribute. Negative test.
 */
public void testXmlAttributeOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67164
Project: 67164
Buggy source:
/** 
 * Tests @XmlAttribute override via eclipselink-oxm.xml.   Positive test.
 */
public void testXmlAttributeOverride(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlAttribute override via eclipselink-oxm.xml.   Positive test.
 */
public void testXmlAttributeOverride(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67165
Project: 67165
Buggy source:
/** 
 * Tests @XmlElement override via eclipselink-oxm.xml.   Positive test.
 */
public void testXmlElementOverride(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,2);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlElement override via eclipselink-oxm.xml.   Positive test.
 */
public void testXmlElementOverride(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,2);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67166
Project: 67166
Buggy source:
/** 
 * Tests @XmlElement override via eclipselink-oxm.xml.  The myUtilDate  element is set to 'required' in the xml file, but the instance  document does not have a myUtilDate element. Negative test.
 */
public void testXmlElementOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,2);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlElement override via eclipselink-oxm.xml.  The myUtilDate  element is set to 'required' in the xml file, but the instance  document does not have a myUtilDate element. Negative test.
 */
public void testXmlElementOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,2);
    String controlSchema=PATH + "String_Node_Str";
    compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE),new File(controlSchema));
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67167
Project: 67167
Buggy source:
/** 
 * Tests @XmlRootElement override via eclipselink-oxm.xml.  @XmlRootElement name 'employee' is overridden as 'employee-data'. Negative test.
 */
public void testXmlRootElementOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlRootElement override via eclipselink-oxm.xml.  @XmlRootElement name 'employee' is overridden as 'employee-data'. Negative test.
 */
public void testXmlRootElementOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67168
Project: 67168
Buggy source:
/** 
 * Tests @XmlRootElement override via eclipselink-oxm.xml.  @XmlRootElement name 'employee' is overridden as 'employee-data'. Positive test.
 */
public void testXmlRootElementOverrideValid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlRootElement override via eclipselink-oxm.xml.  @XmlRootElement name 'employee' is overridden as 'employee-data'. Positive test.
 */
public void testXmlRootElementOverrideValid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67169
Project: 67169
Buggy source:
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. This test case should fail due to an invalid namespace. Negative test.
 */
public void testInvalidEmployeeValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. This test case should fail due to an invalid namespace. Negative test.
 */
public void testInvalidEmployeeValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67170
Project: 67170
Buggy source:
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. This test case should fail due to an invalid namespace. Negative test.
 */
public void testInvalidAddressValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. This test case should fail due to an invalid namespace. Negative test.
 */
public void testInvalidAddressValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67171
Project: 67171
Buggy source:
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. Positive test.
 */
public void testEmployeeValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. Positive test.
 */
public void testEmployeeValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67172
Project: 67172
Buggy source:
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. Positive test.
 */
public void testAddressValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests XmlSchema namespace declaration via eclipselink-oxm.xml.  The namespace information in package-info.java should be overridden. Positive test.
 */
public void testAddressValidation(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67174
Project: 67174
Buggy source:
/** 
 * Tests generation of an xml-see-also class from a package different than Employee's Positive test.
 */
public void testXmlSeeAlsoOtherPackage(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,2);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String messages="String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests generation of an xml-see-also class from a package different than Employee's Positive test.
 */
public void testXmlSeeAlsoOtherPackage(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,2);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String messages="String_Node_Str";
  String result=validateAgainstSchema(src,"String_Node_Str",outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67175
Project: 67175
Buggy source:
/** 
 * Tests generation for Employee when xml-see-also is defined.  Overrides the
 * @XmlSeeAlso on Employee (XmlSeeAlsoTestCases.class) with (MySimpleClass, MyOtherClass) Positive test.
 */
public void testEmployeeGeneration(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,2);
    shouldGenerateSchema=false;
  }
  String messages="String_Node_Str";
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests generation for Employee when xml-see-also is defined.  Overrides the
 * @XmlSeeAlso on Employee (XmlSeeAlsoTestCases.class) with (MySimpleClass, MyOtherClass) Positive test.
 */
public void testEmployeeGeneration(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,2);
    shouldGenerateSchema=false;
  }
  String messages="String_Node_Str";
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67176
Project: 67176
Buggy source:
/** 
 * Tests generation of an xml-see-also class in the same package as Employee Positive test.
 */
public void testXmlSeeAlsoSamePackage(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,2);
    shouldGenerateSchema=false;
  }
  String messages="String_Node_Str";
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests generation of an xml-see-also class in the same package as Employee Positive test.
 */
public void testXmlSeeAlsoSamePackage(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,2);
    shouldGenerateSchema=false;
  }
  String messages="String_Node_Str";
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67177
Project: 67177
Buggy source:
/** 
 * Test marking the Address class as transient. Validation for employee.xml should succeed. Positive test.
 */
public void testXmlTransientOnClassValid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Test marking the Address class as transient. Validation for employee.xml should succeed. Positive test.
 */
public void testXmlTransientOnClassValid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67178
Project: 67178
Buggy source:
/** 
 * Test marking the Address class as transient. Validation for address.xml should fail as Address is marked transient. Negative test.
 */
public void testXmlTransientOnClassInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Test marking the Address class as transient. Validation for address.xml should fail as Address is marked transient. Negative test.
 */
public void testXmlTransientOnClassInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67179
Project: 67179
Buggy source:
/** 
 * Test marking the myInt property on Employee as transient. Validation for employee-invalidproperty.xml should fail. Negative test.
 */
public void testXmlTransientOnProperty(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Test marking the myInt property on Employee as transient. Validation for employee-invalidproperty.xml should fail. Negative test.
 */
public void testXmlTransientOnProperty(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67180
Project: 67180
Buggy source:
/** 
 * Test marking the lastName field on Employee as transient. Validation for employee-invalidfield.xml should fail. Negative test.
 */
public void testXmlTransientOnField(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Test marking the lastName field on Employee as transient. Validation for employee-invalidfield.xml should fail. Negative test.
 */
public void testXmlTransientOnField(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String result=validateAgainstSchema(PATH + "String_Node_Str",null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67181
Project: 67181
Buggy source:
/** 
 * Tests @XmlType override via eclipselink-oxm.xml.  Overrides type  name (my-employee-type) with (employee-type) and propOrder  ("id", "firstName", "lastName") with ("id", "lastName", "firstName") Positive test.
 */
public void testEmployeeXmlTypeOverride(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlType override via eclipselink-oxm.xml.  Overrides type  name (my-employee-type) with (employee-type) and propOrder  ("id", "firstName", "lastName") with ("id", "lastName", "firstName") Positive test.
 */
public void testEmployeeXmlTypeOverride(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,EMPTY_NAMESPACE,outputResolver);
  assertTrue("String_Node_Str" + result,result == null);
}
Program: 67182
Project: 67182
Buggy source:
/** 
 * Tests @XmlType override via eclipselink-oxm.xml.  Overrides type  name (my-employee-type) with (employee-type) and propOrder  ("id", "firstName", "lastName") with ("id", "lastName", "firstName") Negative test.
 */
public void testEmployeeXmlTypeOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}

Fixed version (ground truth):
/** 
 * Tests @XmlType override via eclipselink-oxm.xml.  Overrides type  name (my-employee-type) with (employee-type) and propOrder  ("id", "firstName", "lastName") with ("id", "lastName", "firstName") Negative test.
 */
public void testEmployeeXmlTypeOverrideInvalid(){
  if (shouldGenerateSchema) {
    outputResolver=generateSchema(CONTEXT_PATH,PATH,1);
    shouldGenerateSchema=false;
  }
  String src=PATH + "String_Node_Str";
  String result=validateAgainstSchema(src,null,outputResolver);
  assertTrue("String_Node_Str",result != null);
}
Program: 67184
Project: 67184
Buggy source:
/** 
 * This exception would typically be used by JAXBContextFactory during externalized metadata processing (i.e. eclipselink-oxm.xml).  This exception applies to the case where the Value (in the package name  to metadata source map) is null.
 * @return
 */
public static JAXBException nullMetadataSource(String key){
  Object[] args={key};
  JAXBException exception=new JAXBException(ExceptionMessageGenerator.buildMessage(JAXBException.class,NULL_METADATA_SOURCE,args));
  exception.setErrorCode(NULL_METADATA_SOURCE);
  return exception;
}

Fixed version (ground truth):
/** 
 * This exception would typically be used by JAXBContextFactory during externalized metadata processing (i.e. eclipselink-oxm.xml).  This exception applies to the case where the Value (in the package name  to metadata source map) is null.
 * @param key
 * @return
 */
public static JAXBException nullMetadataSource(String key){
  Object[] args={key};
  JAXBException exception=new JAXBException(ExceptionMessageGenerator.buildMessage(JAXBException.class,NULL_METADATA_SOURCE,args));
  exception.setErrorCode(NULL_METADATA_SOURCE);
  return exception;
}
Program: 67185
Project: 67185
Buggy source:
/** 
 * This exception would typically be used by JAXBContextFactory during externalized metadata processing (i.e. eclipselink-oxm.xml).  This exception applies to the case where JAXBContext creation fails for our XmlModel.
 * @param e
 * @return
 */
public static JAXBException couldNotCreateContextForXmlModel(Exception ex){
  Object[] args={ex};
  JAXBException exception=new JAXBException(ExceptionMessageGenerator.buildMessage(JAXBException.class,COULD_NOT_CREATE_CONTEXT_FOR_XML_MODEL,args),ex);
  exception.setErrorCode(COULD_NOT_CREATE_CONTEXT_FOR_XML_MODEL);
  return exception;
}

Fixed version (ground truth):
/** 
 * This exception would typically be used by JAXBContextFactory during externalized metadata processing (i.e. eclipselink-oxm.xml).  This exception applies to the case where JAXBContext creation fails for our XmlModel.
 * @param ex
 * @return
 */
public static JAXBException couldNotCreateContextForXmlModel(Exception ex){
  Object[] args={ex};
  JAXBException exception=new JAXBException(ExceptionMessageGenerator.buildMessage(JAXBException.class,COULD_NOT_CREATE_CONTEXT_FOR_XML_MODEL,args),ex);
  exception.setErrorCode(COULD_NOT_CREATE_CONTEXT_FOR_XML_MODEL);
  return exception;
}
Program: 67186
Project: 67186
Buggy source:
/** 
 * This exception would typically be used by JAXBContextFactory during externalized metadata processing (i.e. eclipselink-oxm.xml).  This exception applies to the case where an exception occurs while unmarshalling  the eclipselink metadata file.
 * @param e
 * @param metadataSystemId
 * @return
 */
public static JAXBException couldNotUnmarshalMetadata(Exception e){
  Object[] args={};
  JAXBException exception=new JAXBException(ExceptionMessageGenerator.buildMessage(JAXBException.class,COULD_NOT_UNMARSHAL_METADATA,args),e);
  exception.setErrorCode(COULD_NOT_UNMARSHAL_METADATA);
  return exception;
}

Fixed version (ground truth):
/** 
 * This exception would typically be used by JAXBContextFactory during externalized metadata processing (i.e. eclipselink-oxm.xml).  This exception applies to the case where an exception occurs while unmarshalling  the eclipselink metadata file.
 * @param e
 * @return
 */
public static JAXBException couldNotUnmarshalMetadata(Exception e){
  Object[] args={};
  JAXBException exception=new JAXBException(ExceptionMessageGenerator.buildMessage(JAXBException.class,COULD_NOT_UNMARSHAL_METADATA,args),e);
  exception.setErrorCode(COULD_NOT_UNMARSHAL_METADATA);
  return exception;
}
Program: 67187
Project: 67187
Buggy source:
public static Test suite(){
  TestSuite suite=new TestSuite("String_Node_Str");
  suite.addTestSuite(XmlTransientTestCases.class);
  suite.addTestSuite(XmlSeeAlsoTestCases.class);
  suite.addTestSuite(XmlSchemaTestCases.class);
  suite.addTestSuite(XmlRootElementTestCases.class);
  suite.addTestSuite(XmlTypeTestCases.class);
  suite.addTestSuite(XmlAccessorTypeTestCases.class);
  suite.addTestSuite(XmlAccessorOrderTestCases.class);
  suite.addTestSuite(JAXBContextFactoryTestCases.class);
  suite.addTestSuite(XmlElementTestCases.class);
  suite.addTestSuite(XmlAdapterTestCases.class);
  suite.addTestSuite(XmlAttributeTestCases.class);
  suite.addTestSuite(ExceptionHandlingTestCases.class);
  return suite;
}

Fixed version (ground truth):
public static Test suite(){
  TestSuite suite=new TestSuite("String_Node_Str");
  suite.addTestSuite(XmlTransientTestCases.class);
  suite.addTestSuite(XmlSeeAlsoTestCases.class);
  suite.addTestSuite(XmlSchemaTestCases.class);
  suite.addTestSuite(XmlRootElementTestCases.class);
  suite.addTestSuite(XmlTypeTestCases.class);
  suite.addTestSuite(XmlAccessorTypeTestCases.class);
  suite.addTestSuite(XmlAccessorOrderTestCases.class);
  suite.addTestSuite(JAXBContextFactoryTestCases.class);
  suite.addTestSuite(XmlElementTestCases.class);
  suite.addTestSuite(XmlAdapterTestCases.class);
  suite.addTestSuite(XmlAttributeTestCases.class);
  suite.addTestSuite(ExceptionHandlingTestCases.class);
  suite.addTestSuite(XmlCustomizerTestCases.class);
  suite.addTestSuite(CustomizerExceptionTestCases.class);
  return suite;
}
Program: 67191
Project: 67191
Buggy source:
public void openStartElement(XPathFragment xPathFragment,NamespaceResolver namespaceResolver){
  super.openStartElement(xPathFragment,namespaceResolver);
  try {
    String namespaceURI=resolveNamespacePrefix(xPathFragment,namespaceResolver);
    if (namespaceURI == null) {
      xmlStreamWriter.writeStartElement(xPathFragment.getLocalName());
      String defaultNamespace=xmlStreamWriter.getNamespaceContext().getNamespaceURI("String_Node_Str");
      if (defaultNamespace != null && !defaultNamespace.equals("String_Node_Str")) {
        xmlStreamWriter.writeDefaultNamespace("String_Node_Str");
      }
    }
 else {
      String prefix=xPathFragment.getPrefix();
      if (prefix == null) {
        prefix="String_Node_Str";
      }
      xmlStreamWriter.writeStartElement(prefix,xPathFragment.getLocalName(),namespaceURI);
    }
    writePrefixMappings();
  }
 catch (  XMLStreamException e) {
    throw XMLMarshalException.marshalException(e);
  }
}

Fixed version (ground truth):
public void openStartElement(XPathFragment xPathFragment,NamespaceResolver namespaceResolver){
  super.openStartElement(xPathFragment,namespaceResolver);
  try {
    String namespaceURI=resolveNamespacePrefix(xPathFragment,namespaceResolver);
    if (namespaceURI == null) {
      xmlStreamWriter.writeStartElement("String_Node_Str",xPathFragment.getLocalName(),"String_Node_Str");
      String defaultNamespace=xmlStreamWriter.getNamespaceContext().getNamespaceURI("String_Node_Str");
      if (defaultNamespace != null && !defaultNamespace.equals("String_Node_Str")) {
        xmlStreamWriter.writeDefaultNamespace("String_Node_Str");
      }
    }
 else {
      String prefix=xPathFragment.getPrefix();
      if (prefix == null) {
        prefix="String_Node_Str";
      }
      xmlStreamWriter.writeStartElement(prefix,xPathFragment.getLocalName(),namespaceURI);
    }
    writePrefixMappings();
  }
 catch (  XMLStreamException e) {
    throw XMLMarshalException.marshalException(e);
  }
}
Program: 67192
Project: 67192
Buggy source:
public void addTests(){
  addSRGTests();
  addAdvancedSybaseExpressionFunctionTest();
  addAdvancedDB2ExpressionFunctionTest();
  addInCollectionTest();
  addTest(new LiteralExpressionTest());
}

Fixed version (ground truth):
public void addTests(){
  addSRGTests();
  addAdvancedSybaseExpressionFunctionTest();
  addAdvancedDB2ExpressionFunctionTest();
  addInCollectionTest();
  addTest(new LiteralExpressionTest());
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",true));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",false));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",true));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",false));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",true));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",false));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",true));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",false));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",true));
  addTest(new LiteralSQLExpressionWithQuestionMarkTest("String_Node_Str",false));
}
Program: 67194
Project: 67194
Buggy source:
public void testDeleteCustomer(){
  EntityManager em=createEntityManager(m_persistenceUnit);
  beginTransaction(em);
  try {
    em.remove(em.find(Customer.class,customerId));
    commitTransaction(em);
  }
 catch (  RuntimeException e) {
    if (isTransactionActive(em)) {
      rollbackTransaction(em);
    }
    closeEntityManager(em);
    throw e;
  }
  assertTrue("String_Node_Str",em.find(Customer.class,customerId) == null);
  closeEntityManager(em);
}

Fixed version (ground truth):
public void testDeleteCustomer(){
  EntityManager em=createEntityManager(m_persistenceUnit);
  beginTransaction(em);
  try {
    Customer c=em.find(Customer.class,customerId);
    em.refresh(c);
    em.remove(c);
    commitTransaction(em);
  }
 catch (  RuntimeException e) {
    if (isTransactionActive(em)) {
      rollbackTransaction(em);
    }
    closeEntityManager(em);
    throw e;
  }
  assertTrue("String_Node_Str",em.find(Customer.class,customerId) == null);
  closeEntityManager(em);
}
Program: 67195
Project: 67195
Buggy source:
@Override public void customize(ClassDescriptor descriptor) throws Exception {
  XMLDirectMapping firstNameMapping=(XMLDirectMapping)descriptor.getMappingForAttributeName("String_Node_Str");
  XMLField fnxField=(XMLField)firstNameMapping.getField();
  fnxField.setXPath("String_Node_Str");
  XMLDirectMapping lastNameMapping=(XMLDirectMapping)descriptor.getMappingForAttributeName("String_Node_Str");
  XMLField lnxField=(XMLField)lastNameMapping.getField();
  lnxField.setXPath("String_Node_Str");
}

Fixed version (ground truth):
public void customize(ClassDescriptor descriptor) throws Exception {
  XMLDirectMapping firstNameMapping=(XMLDirectMapping)descriptor.getMappingForAttributeName("String_Node_Str");
  XMLField fnxField=(XMLField)firstNameMapping.getField();
  fnxField.setXPath("String_Node_Str");
  XMLDirectMapping lastNameMapping=(XMLDirectMapping)descriptor.getMappingForAttributeName("String_Node_Str");
  XMLField lnxField=(XMLField)lastNameMapping.getField();
  lnxField.setXPath("String_Node_Str");
}
Program: 67197
Project: 67197
Buggy source:
public void endElement(XPathFragment xPathFragment,UnmarshalRecord unmarshalRecord){
  unmarshalRecord.removeNullCapableValue(this);
  XMLField xmlField=(XMLField)xmlDirectMapping.getField();
  if (!xmlField.getLastXPathFragment().nameIsText()) {
    return;
  }
  Object value=unmarshalRecord.getStringBuffer().toString();
  unmarshalRecord.resetStringBuffer();
  XMLConversionManager xmlConversionManager=(XMLConversionManager)unmarshalRecord.getSession().getDatasourcePlatform().getConversionManager();
  if (unmarshalRecord.getTypeQName() != null) {
    Class typeClass=xmlField.getJavaClass(unmarshalRecord.getTypeQName());
    value=xmlConversionManager.convertObject(value,typeClass,unmarshalRecord.getTypeQName());
  }
 else {
    value=xmlField.convertValueBasedOnSchemaType(value,xmlConversionManager,unmarshalRecord);
  }
  Object convertedValue=xmlDirectMapping.getAttributeValue(value,unmarshalRecord.getSession(),unmarshalRecord);
  unmarshalRecord.setAttributeValue(convertedValue,xmlDirectMapping);
}

Fixed version (ground truth):
public void endElement(XPathFragment xPathFragment,UnmarshalRecord unmarshalRecord){
  unmarshalRecord.removeNullCapableValue(this);
  XMLField xmlField=(XMLField)xmlDirectMapping.getField();
  if (!xmlField.getLastXPathFragment().nameIsText()) {
    return;
  }
  Object value;
  if (unmarshalRecord.getStringBuffer().length() == 0) {
    value=this.getMapping().getNullValue();
  }
 else {
    value=unmarshalRecord.getStringBuffer().toString();
  }
  unmarshalRecord.resetStringBuffer();
  XMLConversionManager xmlConversionManager=(XMLConversionManager)unmarshalRecord.getSession().getDatasourcePlatform().getConversionManager();
  if (unmarshalRecord.getTypeQName() != null) {
    Class typeClass=xmlField.getJavaClass(unmarshalRecord.getTypeQName());
    value=xmlConversionManager.convertObject(value,typeClass,unmarshalRecord.getTypeQName());
  }
 else {
    value=xmlField.convertValueBasedOnSchemaType(value,xmlConversionManager,unmarshalRecord);
  }
  Object convertedValue=xmlDirectMapping.getAttributeValue(value,unmarshalRecord.getSession(),unmarshalRecord);
  unmarshalRecord.setAttributeValue(convertedValue,xmlDirectMapping);
}
Program: 67198
Project: 67198
Buggy source:
public SAXUnmarshaller(XMLUnmarshaller xmlUnmarshaller) throws XMLMarshalException {
  super();
  try {
    saxParserFactory=SAXParserFactory.newInstance();
    saxParserFactory.setNamespaceAware(true);
    saxParserFactory.setFeature("String_Node_Str",true);
    saxParser=saxParserFactory.newSAXParser();
    xmlReader=new XMLReader(saxParser.getXMLReader());
    DefaultErrorHandler handler=new DefaultErrorHandler();
    xmlReader.setErrorHandler(handler);
    xmlParser=XMLPlatformFactory.getInstance().getXMLPlatform().newXMLParser();
    xmlParser.setNamespaceAware(true);
    xmlParser.setValidationMode(XMLParser.NONVALIDATING);
    this.xmlUnmarshaller=xmlUnmarshaller;
  }
 catch (  Exception e) {
    throw XMLMarshalException.errorInstantiatingSchemaPlatform(e);
  }
}

Fixed version (ground truth):
public SAXUnmarshaller(XMLUnmarshaller xmlUnmarshaller) throws XMLMarshalException {
  super();
  try {
    saxParserFactory=SAXParserFactory.newInstance();
    saxParserFactory.setNamespaceAware(true);
    saxParserFactory.setFeature("String_Node_Str",true);
    saxParserFactory.setFeature("String_Node_Str",false);
    saxParser=saxParserFactory.newSAXParser();
    xmlReader=new XMLReader(saxParser.getXMLReader());
    DefaultErrorHandler handler=new DefaultErrorHandler();
    xmlReader.setErrorHandler(handler);
    xmlParser=XMLPlatformFactory.getInstance().getXMLPlatform().newXMLParser();
    xmlParser.setNamespaceAware(true);
    xmlParser.setValidationMode(XMLParser.NONVALIDATING);
    this.xmlUnmarshaller=xmlUnmarshaller;
  }
 catch (  Exception e) {
    throw XMLMarshalException.errorInstantiatingSchemaPlatform(e);
  }
}
Program: 67212
Project: 67212
Buggy source:
public void processSimpleElement() throws SAXException {
  getEvents().remove(0);
  executeEvents(new XMLInlineBinaryHandler(this.getParent(),nodeValue,mapping,converter,isCollection));
}

Fixed version (ground truth):
public void processSimpleElement() throws SAXException {
  getEvents().remove(0);
  workingUnmarshalRecord=new XMLInlineBinaryHandler(this.getParent(),nodeValue,mapping,converter,isCollection);
  executeEvents(workingUnmarshalRecord);
}
Program: 67213
Project: 67213
Buggy source:
public void processComplexElement() throws SAXException {
  getEvents().remove(0);
  executeEvents(new XMLBinaryAttachmentHandler(this.getParent(),nodeValue,mapping,converter,isCollection));
}

Fixed version (ground truth):
public void processComplexElement() throws SAXException {
  getEvents().remove(0);
  workingUnmarshalRecord=new XMLBinaryAttachmentHandler(this.getParent(),nodeValue,mapping,converter,isCollection);
  executeEvents(workingUnmarshalRecord);
}
Program: 67216
Project: 67216
Buggy source:
public void testSequenceObjectDefinition(){
  EntityManager em=createEntityManager();
  ServerSession ss=getServerSession();
  if (!ss.getLogin().getPlatform().supportsSequenceObjects()) {
    closeEntityManager(em);
    return;
  }
  String seqName="String_Node_Str";
  try {
    internalTestSequenceObjectDefinition(10,1,seqName,em,ss);
    internalTestSequenceObjectDefinition(10,5,seqName,em,ss);
    internalTestSequenceObjectDefinition(10,15,seqName,em,ss);
  }
  finally {
    closeEntityManager(em);
  }
}

Fixed version (ground truth):
public void testSequenceObjectDefinition(){
  EntityManager em=createEntityManager();
  ServerSession ss=getServerSession();
  if (!ss.getLogin().getPlatform().supportsSequenceObjects() || isOnServer()) {
    closeEntityManager(em);
    return;
  }
  String seqName="String_Node_Str";
  try {
    internalTestSequenceObjectDefinition(10,1,seqName,em,ss);
    internalTestSequenceObjectDefinition(10,5,seqName,em,ss);
    internalTestSequenceObjectDefinition(10,15,seqName,em,ss);
  }
  finally {
    closeEntityManager(em);
  }
}
Program: 67223
Project: 67223
Buggy source:
public void characters(char[] ch,int start,int length) throws SAXException {
  try {
    if (null != selfRecords) {
      int selfRecordsSize=selfRecords.size();
      for (int x=0; x < selfRecordsSize; x++) {
        UnmarshalRecord selfRecord=((UnmarshalRecord)selfRecords.get(x));
        if (selfRecord != null) {
          selfRecord.characters(ch,start,length);
        }
      }
    }
    XPathNode textNode=xPathNode.getTextNode();
    if (null == textNode && xPathNode.getNonAttributeChildrenMap() != null) {
      textNode=(XPathNode)xPathNode.getNonAttributeChildrenMap().get(XPathFragment.ANY_FRAGMENT);
      if (textNode != null) {
        if (0 == length) {
          return;
        }
        String tmpString=new String(ch,start,length);
        if (EMPTY_STRING.equals(tmpString.trim()) && !textNode.isWhitespaceAware()) {
          return;
        }
      }
    }
    if (null != textNode) {
      xPathNode=textNode;
      unmarshalContext.characters(this);
    }
    if (null != xPathNode.getUnmarshalNodeValue()) {
      stringBuffer.append(ch,start,length);
    }
  }
 catch (  EclipseLinkException e) {
    if (null == xmlReader.getErrorHandler()) {
      throw e;
    }
 else {
      SAXParseException saxParseException=new SAXParseException(null,null,null,0,0,e);
      xmlReader.getErrorHandler().error(saxParseException);
    }
  }
}

Fixed version (ground truth):
public void characters(char[] ch,int start,int length) throws SAXException {
  try {
    if (null != selfRecords) {
      int selfRecordsSize=selfRecords.size();
      for (int x=0; x < selfRecordsSize; x++) {
        UnmarshalRecord selfRecord=((UnmarshalRecord)selfRecords.get(x));
        if (selfRecord != null) {
          selfRecord.characters(ch,start,length);
        }
 else {
          getFragmentBuilder().characters(ch,start,length);
        }
      }
    }
    XPathNode textNode=xPathNode.getTextNode();
    if (null == textNode && xPathNode.getNonAttributeChildrenMap() != null) {
      textNode=(XPathNode)xPathNode.getNonAttributeChildrenMap().get(XPathFragment.ANY_FRAGMENT);
      if (textNode != null) {
        if (0 == length) {
          return;
        }
        String tmpString=new String(ch,start,length);
        if (EMPTY_STRING.equals(tmpString.trim()) && !textNode.isWhitespaceAware()) {
          return;
        }
      }
    }
    if (null != textNode) {
      xPathNode=textNode;
      unmarshalContext.characters(this);
    }
    if (null != xPathNode.getUnmarshalNodeValue()) {
      stringBuffer.append(ch,start,length);
    }
  }
 catch (  EclipseLinkException e) {
    if (null == xmlReader.getErrorHandler()) {
      throw e;
    }
 else {
      SAXParseException saxParseException=new SAXParseException(null,null,null,0,0,e);
      xmlReader.getErrorHandler().error(saxParseException);
    }
  }
}
Program: 67226
Project: 67226
Buggy source:
protected void xmlToObjectTest(Object testObject,String resource,String testCase) throws Exception {
  log("String_Node_Str" + testCase + "String_Node_Str");
  log("String_Node_Str");
  log(getReadControlObject(resource).toString());
  log("String_Node_Str");
  log(testObject.toString());
  log("String_Node_Str");
  assertEquals(getReadControlObject(resource),testObject);
}

Fixed version (ground truth):
protected void xmlToObjectTest(Object testObject,String resource,String testCase) throws Exception {
  log("String_Node_Str" + testCase + "String_Node_Str");
  log("String_Node_Str");
  log(getReadControlObject(resource).toString());
  log("String_Node_Str");
  log(testObject.toString());
  log("String_Node_Str");
  Employee testEmp=(Employee)testObject;
  removeEmptyTextNodes(testEmp.xmlNode);
  Employee controlEmp=(Employee)getReadControlObject(resource);
  removeEmptyTextNodes(controlEmp.xmlNode);
  assertEquals(controlEmp,testEmp);
}
Program: 67228
Project: 67228
Buggy source:
/** 
 * INTRENAL:
 */
public String getQualifiedName(){
  if (qualifiedName == null) {
    DatabaseMapping mapping=queryKeyExpression.getMapping();
    DatabaseTable nestedTable=mapping.getDescriptor().getTables().firstElement();
    DatabaseTable tableAlias=queryKeyExpression.getBaseExpression().aliasForTable(nestedTable);
    DatabaseTable nestedTableAlias=queryKeyExpression.aliasForTable(this);
    StringBuffer name=new StringBuffer();
    name.append("String_Node_Str");
    name.append(tableAlias.getName());
    name.append("String_Node_Str");
    name.append(mapping.getField().getNameDelimited());
    name.append("String_Node_Str");
    qualifiedName=name.toString();
  }
  return qualifiedName;
}

Fixed version (ground truth):
private String getQualifiedName(boolean allowDelimiters){
  if (qualifiedName == null) {
    DatabaseMapping mapping=queryKeyExpression.getMapping();
    DatabaseTable nestedTable=mapping.getDescriptor().getTables().firstElement();
    DatabaseTable tableAlias=queryKeyExpression.getBaseExpression().aliasForTable(nestedTable);
    DatabaseTable nestedTableAlias=queryKeyExpression.aliasForTable(this);
    StringBuffer name=new StringBuffer();
    name.append("String_Node_Str");
    if (allowDelimiters && useDelimiters) {
      name.append(Helper.getStartDatabaseDelimiter());
    }
    name.append(tableAlias.getName());
    if (allowDelimiters && useDelimiters) {
      name.append(Helper.getEndDatabaseDelimiter());
    }
    name.append("String_Node_Str");
    if (allowDelimiters && useDelimiters) {
      name.append(Helper.getStartDatabaseDelimiter());
    }
    name.append(mapping.getField().getNameDelimited());
    if (allowDelimiters && useDelimiters) {
      name.append(Helper.getEndDatabaseDelimiter());
    }
    name.append("String_Node_Str");
    qualifiedName=name.toString();
  }
  return qualifiedName;
}