nus-yam/ex-repair huggingface dataset:
Program: 17864
Project: 17864
Buggy source:
@Test public void testExtendedODataErrorContext() throws Exception {
  MultivaluedMap<String,String> value=new MultivaluedHashMap<String,String>();
  value.putSingle("String_Node_Str","String_Node_Str");
  value.put("String_Node_Str",Arrays.asList("String_Node_Str","String_Node_Str"));
  when(exceptionMapper.httpHeaders.getRequestHeaders()).thenReturn(value);
  when(exceptionMapper.servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL)).thenReturn(ODataServiceFactoryImpl.class.getName());
  Response response=exceptionMapper.toResponse(new Exception());
  assertNotNull(response);
  assertEquals(HttpStatusCodes.BAD_REQUEST.getStatusCode(),response.getStatus());
  String errorMessage=(String)response.getEntity();
  assertEquals("String_Node_Str",errorMessage);
  String contentTypeHeader=response.getHeaderString(com.sap.core.odata.api.commons.HttpHeaders.CONTENT_TYPE);
  assertEquals("String_Node_Str",contentTypeHeader);
  assertEquals(uri.toASCIIString(),response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
}

Fixed version (ground truth):
@Test public void testExtendedODataErrorContext() throws Exception {
  MultivaluedMap<String,String> value=new MultivaluedHashMap<String,String>();
  value.putSingle("String_Node_Str","String_Node_Str");
  value.put("String_Node_Str",Arrays.asList("String_Node_Str","String_Node_Str"));
  when(exceptionMapper.httpHeaders.getRequestHeaders()).thenReturn(value);
  when(exceptionMapper.servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL)).thenReturn(ODataServiceFactoryImpl.class.getName());
  when(exceptionMapper.servletRequest.getAttribute(ODataServiceFactory.FACTORY_CLASSLOADER_LABEL)).thenReturn(null);
  Response response=exceptionMapper.toResponse(new Exception());
  assertNotNull(response);
  assertEquals(HttpStatusCodes.BAD_REQUEST.getStatusCode(),response.getStatus());
  String errorMessage=(String)response.getEntity();
  assertEquals("String_Node_Str",errorMessage);
  String contentTypeHeader=response.getHeaderString(com.sap.core.odata.api.commons.HttpHeaders.CONTENT_TYPE);
  assertEquals("String_Node_Str",contentTypeHeader);
  assertEquals(uri.toASCIIString(),response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
}
Program: 17865
Project: 17865
Buggy source:
public ODataExceptionWrapper(final UriInfo uriInfo,final HttpHeaders httpHeaders,final ServletConfig servletConfig){
  contentType=getContentType(uriInfo,httpHeaders).toContentTypeString();
  messageLocale=MessageService.getSupportedLocale(getLanguages(httpHeaders),DEFAULT_RESPONSE_LOCALE);
  httpRequestHeaders=httpHeaders.getRequestHeaders();
  requestUri=uriInfo.getRequestUri();
  try {
    callback=getErrorHandlerCallbackFromServletConfig(servletConfig);
  }
 catch (  Exception e) {
    throw new ODataRuntimeException("String_Node_Str",e);
  }
}

Fixed version (ground truth):
public ODataExceptionWrapper(final UriInfo uriInfo,final HttpHeaders httpHeaders,final ServletConfig servletConfig,final HttpServletRequest servletRequest){
  contentType=getContentType(uriInfo,httpHeaders).toContentTypeString();
  messageLocale=MessageService.getSupportedLocale(getLanguages(httpHeaders),DEFAULT_RESPONSE_LOCALE);
  httpRequestHeaders=httpHeaders.getRequestHeaders();
  requestUri=uriInfo.getRequestUri();
  try {
    callback=getErrorHandlerCallbackFromServletConfig(servletConfig,servletRequest);
  }
 catch (  Exception e) {
    throw new ODataRuntimeException("String_Node_Str",e);
  }
}
Program: 17866
Project: 17866
Buggy source:
private ODataErrorCallback getErrorHandlerCallbackFromServletConfig(final ServletConfig servletConfig) throws InstantiationException, IllegalAccessException, ClassNotFoundException {
  ODataErrorCallback callback=null;
  final String factoryClassName=servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL);
  if (factoryClassName != null) {
    Class<?> factoryClass=Class.forName(factoryClassName);
    final ODataServiceFactory serviceFactory=(ODataServiceFactory)factoryClass.newInstance();
    callback=serviceFactory.getCallback(ODataErrorCallback.class);
  }
  return callback;
}

Fixed version (ground truth):
private ODataErrorCallback getErrorHandlerCallbackFromServletConfig(final ServletConfig servletConfig,HttpServletRequest servletRequest) throws InstantiationException, IllegalAccessException, ClassNotFoundException {
  ODataErrorCallback callback=null;
  final String factoryClassName=servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL);
  if (factoryClassName != null) {
    ClassLoader cl=(ClassLoader)servletRequest.getAttribute(ODataServiceFactory.FACTORY_CLASSLOADER_LABEL);
    Class<?> factoryClass;
    if (cl == null) {
      factoryClass=Class.forName(factoryClassName);
    }
 else {
      factoryClass=Class.forName(factoryClassName,true,cl);
    }
    final ODataServiceFactory serviceFactory=(ODataServiceFactory)factoryClass.newInstance();
    callback=serviceFactory.getCallback(ODataErrorCallback.class);
  }
  return callback;
}
Program: 17867
Project: 17867
Buggy source:
private ODataErrorCallback getErrorHandlerCallback() throws ClassNotFoundException, InstantiationException, IllegalAccessException {
  ODataErrorCallback callback=null;
  final String factoryClassName=servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL);
  if (factoryClassName != null) {
    Class<?> factoryClass=Class.forName(factoryClassName);
    final ODataServiceFactory serviceFactory=(ODataServiceFactory)factoryClass.newInstance();
    callback=serviceFactory.getCallback(ODataErrorCallback.class);
  }
  return callback;
}

Fixed version (ground truth):
private ODataErrorCallback getErrorHandlerCallback() throws ClassNotFoundException, InstantiationException, IllegalAccessException {
  ODataErrorCallback callback=null;
  final String factoryClassName=servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL);
  if (factoryClassName != null) {
    ClassLoader cl=(ClassLoader)servletRequest.getAttribute(ODataServiceFactory.FACTORY_CLASSLOADER_LABEL);
    Class<?> factoryClass;
    if (cl == null) {
      factoryClass=Class.forName(factoryClassName);
    }
 else {
      factoryClass=Class.forName(factoryClassName,true,cl);
    }
    final ODataServiceFactory serviceFactory=(ODataServiceFactory)factoryClass.newInstance();
    callback=serviceFactory.getCallback(ODataErrorCallback.class);
  }
  return callback;
}
Program: 17868
Project: 17868
Buggy source:
private ODataResponse handleException(final Exception exception){
  ODataExceptionWrapper exceptionWrapper=new ODataExceptionWrapper(uriInfo,httpHeaders,servletConfig);
  ODataResponse oDataResponse=exceptionWrapper.wrapInExceptionResponse(exception);
  return oDataResponse;
}

Fixed version (ground truth):
private ODataResponse handleException(final Exception exception){
  ODataExceptionWrapper exceptionWrapper=new ODataExceptionWrapper(uriInfo,httpHeaders,servletConfig,servletRequest);
  ODataResponse oDataResponse=exceptionWrapper.wrapInExceptionResponse(exception);
  return oDataResponse;
}
Program: 17869
Project: 17869
Buggy source:
@Before public void before() throws URISyntaxException {
  exceptionMapper=new ODataExceptionMapperImpl();
  exceptionMapper.httpHeaders=mock(HttpHeaders.class);
  exceptionMapper.uriInfo=mock(UriInfo.class);
  exceptionMapper.servletConfig=mock(ServletConfig.class);
  MultivaluedHashMap<String,String> map=new MultivaluedHashMap<String,String>();
  when(exceptionMapper.uriInfo.getQueryParameters()).thenReturn(map);
  uri=new URI("String_Node_Str");
  when(exceptionMapper.uriInfo.getRequestUri()).thenReturn(uri);
  MultivaluedHashMap<String,String> httpHeaders=new MultivaluedHashMap<String,String>();
  when(exceptionMapper.httpHeaders.getRequestHeaders()).thenReturn(httpHeaders);
  disableLogging();
}

Fixed version (ground truth):
@Before public void before() throws URISyntaxException {
  exceptionMapper=new ODataExceptionMapperImpl();
  exceptionMapper.httpHeaders=mock(HttpHeaders.class);
  exceptionMapper.uriInfo=mock(UriInfo.class);
  exceptionMapper.servletConfig=mock(ServletConfig.class);
  exceptionMapper.servletRequest=mock(HttpServletRequest.class);
  MultivaluedHashMap<String,String> map=new MultivaluedHashMap<String,String>();
  when(exceptionMapper.uriInfo.getQueryParameters()).thenReturn(map);
  uri=new URI("String_Node_Str");
  when(exceptionMapper.uriInfo.getRequestUri()).thenReturn(uri);
  MultivaluedHashMap<String,String> httpHeaders=new MultivaluedHashMap<String,String>();
  when(exceptionMapper.httpHeaders.getRequestHeaders()).thenReturn(httpHeaders);
  disableLogging();
}
Program: 17870
Project: 17870
Buggy source:
@Test public void testExtendedODataErrorContext() throws Exception {
  MultivaluedMap<String,String> value=new MultivaluedHashMap<String,String>();
  value.putSingle("String_Node_Str","String_Node_Str");
  value.put("String_Node_Str",Arrays.asList("String_Node_Str","String_Node_Str"));
  when(exceptionMapper.httpHeaders.getRequestHeaders()).thenReturn(value);
  when(exceptionMapper.servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL)).thenReturn(ODataServiceFactoryImpl.class.getName());
  Response response=exceptionMapper.toResponse(new Exception());
  assertNotNull(response);
  assertEquals(HttpStatusCodes.BAD_REQUEST.getStatusCode(),response.getStatus());
  String errorMessage=(String)response.getEntity();
  assertEquals("String_Node_Str",errorMessage);
  String contentTypeHeader=response.getHeaderString(com.sap.core.odata.api.commons.HttpHeaders.CONTENT_TYPE);
  assertEquals("String_Node_Str",contentTypeHeader);
  assertEquals(uri.toASCIIString(),response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
}

Fixed version (ground truth):
@Test public void testExtendedODataErrorContext() throws Exception {
  MultivaluedMap<String,String> value=new MultivaluedHashMap<String,String>();
  value.putSingle("String_Node_Str","String_Node_Str");
  value.put("String_Node_Str",Arrays.asList("String_Node_Str","String_Node_Str"));
  when(exceptionMapper.httpHeaders.getRequestHeaders()).thenReturn(value);
  when(exceptionMapper.servletConfig.getInitParameter(ODataServiceFactory.FACTORY_LABEL)).thenReturn(ODataServiceFactoryImpl.class.getName());
  when(exceptionMapper.servletRequest.getAttribute(ODataServiceFactory.FACTORY_CLASSLOADER_LABEL)).thenReturn(null);
  Response response=exceptionMapper.toResponse(new Exception());
  assertNotNull(response);
  assertEquals(HttpStatusCodes.BAD_REQUEST.getStatusCode(),response.getStatus());
  String errorMessage=(String)response.getEntity();
  assertEquals("String_Node_Str",errorMessage);
  String contentTypeHeader=response.getHeaderString(com.sap.core.odata.api.commons.HttpHeaders.CONTENT_TYPE);
  assertEquals("String_Node_Str",contentTypeHeader);
  assertEquals(uri.toASCIIString(),response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
  assertEquals("String_Node_Str",response.getHeaderString("String_Node_Str"));
}
Program: 17871
Project: 17871
Buggy source:
private void validateEntitySet() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    EntitySet entitySet : container.getValue().getEntitySets()) {
      FullQualifiedName entityType=entitySet.getEntityType();
      if (!(entityTypesMap.containsKey(entityType) && container.getKey().getNamespace().equals(entityType.getNamespace()))) {
        validateEntityTypeWithAlias(entityType);
      }
    }
  }
}

Fixed version (ground truth):
private void validateEntitySet() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    EntitySet entitySet : container.getValue().getEntitySets()) {
      FullQualifiedName entityType=entitySet.getEntityType();
      if (!(entityTypesMap.containsKey(entityType))) {
        validateEntityTypeWithAlias(entityType);
      }
    }
  }
}
Program: 17872
Project: 17872
Buggy source:
private void validateAssociation() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    AssociationSet associationSet : container.getValue().getAssociationSets()) {
      FullQualifiedName association=associationSet.getAssociation();
      if (associationsMap.containsKey(association) && container.getKey().getNamespace().equals(association.getNamespace())) {
        validateAssociationEnd(associationSet.getEnd1(),associationsMap.get(association));
        validateAssociationEnd(associationSet.getEnd2(),associationsMap.get(association));
        boolean end1=false;
        boolean end2=false;
        for (        EntitySet entitySet : container.getValue().getEntitySets()) {
          if (entitySet.getName().equals(associationSet.getEnd1().getEntitySet())) {
            end1=true;
          }
          if (entitySet.getName().equals(associationSet.getEnd2().getEntitySet())) {
            end2=true;
          }
        }
        if (!(end1 && end2)) {
          throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
        }
      }
 else {
        throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
      }
    }
  }
}

Fixed version (ground truth):
private void validateAssociation() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    AssociationSet associationSet : container.getValue().getAssociationSets()) {
      FullQualifiedName association=associationSet.getAssociation();
      if (associationsMap.containsKey(association)) {
        validateAssociationEnd(associationSet.getEnd1(),associationsMap.get(association));
        validateAssociationEnd(associationSet.getEnd2(),associationsMap.get(association));
        boolean end1=false;
        boolean end2=false;
        for (        EntitySet entitySet : container.getValue().getEntitySets()) {
          if (entitySet.getName().equals(associationSet.getEnd1().getEntitySet())) {
            end1=true;
          }
          if (entitySet.getName().equals(associationSet.getEnd2().getEntitySet())) {
            end2=true;
          }
        }
        if (!(end1 && end2)) {
          throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
        }
      }
 else {
        throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
      }
    }
  }
}
Program: 17873
Project: 17873
Buggy source:
@Test public void testAssociationSet() throws XMLStreamException, EntityProviderException {
  EdmParser parser=new EdmParser();
  XMLStreamReader reader=createStreamReader(xmlWithAssociation);
  DataServices result=parser.readMetadata(reader,true);
  for (  Schema schema : result.getSchemas()) {
    for (    EntityContainer container : schema.getEntityContainers()) {
      assertEquals("String_Node_Str",container.getName());
      assertEquals(Boolean.TRUE,container.isDefaultEntityContainer());
      for (      AssociationSet assocSet : container.getAssociationSets()) {
        assertEquals(ASSOCIATION,assocSet.getName());
        assertEquals(ASSOCIATION,assocSet.getAssociation().getName());
        assertEquals(NAMESPACE,assocSet.getAssociation().getNamespace());
        AssociationSetEnd end;
        if ("String_Node_Str".equals(assocSet.getEnd1().getEntitySet())) {
          end=assocSet.getEnd1();
        }
 else {
          end=assocSet.getEnd2();
        }
        assertEquals("String_Node_Str",end.getRole());
      }
    }
  }
}

Fixed version (ground truth):
@Test public void testAssociationSet() throws XMLStreamException, EntityProviderException {
  EdmParser parser=new EdmParser();
  XMLStreamReader reader=createStreamReader(xmlWithAssociation);
  DataServices result=parser.readMetadata(reader,true);
  for (  Schema schema : result.getSchemas()) {
    for (    EntityContainer container : schema.getEntityContainers()) {
      assertEquals(NAMESPACE2,schema.getNamespace());
      assertEquals("String_Node_Str",container.getName());
      assertEquals(Boolean.TRUE,container.isDefaultEntityContainer());
      for (      AssociationSet assocSet : container.getAssociationSets()) {
        assertEquals(ASSOCIATION,assocSet.getName());
        assertEquals(ASSOCIATION,assocSet.getAssociation().getName());
        assertEquals(NAMESPACE,assocSet.getAssociation().getNamespace());
        AssociationSetEnd end;
        if ("String_Node_Str".equals(assocSet.getEnd1().getEntitySet())) {
          end=assocSet.getEnd1();
        }
 else {
          end=assocSet.getEnd2();
        }
        assertEquals("String_Node_Str",end.getRole());
      }
    }
  }
}
Program: 17874
Project: 17874
Buggy source:
private void validateEntitySet() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    EntitySet entitySet : container.getValue().getEntitySets()) {
      FullQualifiedName entityType=entitySet.getEntityType();
      if (!(entityTypesMap.containsKey(entityType) && container.getKey().getNamespace().equals(entityType.getNamespace()))) {
        validateEntityTypeWithAlias(entityType);
      }
    }
  }
}

Fixed version (ground truth):
private void validateEntitySet() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    EntitySet entitySet : container.getValue().getEntitySets()) {
      FullQualifiedName entityType=entitySet.getEntityType();
      if (!(entityTypesMap.containsKey(entityType))) {
        validateEntityTypeWithAlias(entityType);
      }
    }
  }
}
Program: 17875
Project: 17875
Buggy source:
private void validateAssociation() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    AssociationSet associationSet : container.getValue().getAssociationSets()) {
      FullQualifiedName association=associationSet.getAssociation();
      if (associationsMap.containsKey(association) && container.getKey().getNamespace().equals(association.getNamespace())) {
        validateAssociationEnd(associationSet.getEnd1(),associationsMap.get(association));
        validateAssociationEnd(associationSet.getEnd2(),associationsMap.get(association));
        boolean end1=false;
        boolean end2=false;
        for (        EntitySet entitySet : container.getValue().getEntitySets()) {
          if (entitySet.getName().equals(associationSet.getEnd1().getEntitySet())) {
            end1=true;
          }
          if (entitySet.getName().equals(associationSet.getEnd2().getEntitySet())) {
            end2=true;
          }
        }
        if (!(end1 && end2)) {
          throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
        }
      }
 else {
        throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
      }
    }
  }
}

Fixed version (ground truth):
private void validateAssociation() throws EntityProviderException {
  for (  Map.Entry<FullQualifiedName,EntityContainer> container : containerMap.entrySet()) {
    for (    AssociationSet associationSet : container.getValue().getAssociationSets()) {
      FullQualifiedName association=associationSet.getAssociation();
      if (associationsMap.containsKey(association)) {
        validateAssociationEnd(associationSet.getEnd1(),associationsMap.get(association));
        validateAssociationEnd(associationSet.getEnd2(),associationsMap.get(association));
        boolean end1=false;
        boolean end2=false;
        for (        EntitySet entitySet : container.getValue().getEntitySets()) {
          if (entitySet.getName().equals(associationSet.getEnd1().getEntitySet())) {
            end1=true;
          }
          if (entitySet.getName().equals(associationSet.getEnd2().getEntitySet())) {
            end2=true;
          }
        }
        if (!(end1 && end2)) {
          throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
        }
      }
 else {
        throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
      }
    }
  }
}
Program: 17876
Project: 17876
Buggy source:
@Test public void testAssociationSet() throws XMLStreamException, EntityProviderException {
  EdmParser parser=new EdmParser();
  XMLStreamReader reader=createStreamReader(xmlWithAssociation);
  DataServices result=parser.readMetadata(reader,true);
  for (  Schema schema : result.getSchemas()) {
    for (    EntityContainer container : schema.getEntityContainers()) {
      assertEquals("String_Node_Str",container.getName());
      assertEquals(Boolean.TRUE,container.isDefaultEntityContainer());
      for (      AssociationSet assocSet : container.getAssociationSets()) {
        assertEquals(ASSOCIATION,assocSet.getName());
        assertEquals(ASSOCIATION,assocSet.getAssociation().getName());
        assertEquals(NAMESPACE,assocSet.getAssociation().getNamespace());
        AssociationSetEnd end;
        if ("String_Node_Str".equals(assocSet.getEnd1().getEntitySet())) {
          end=assocSet.getEnd1();
        }
 else {
          end=assocSet.getEnd2();
        }
        assertEquals("String_Node_Str",end.getRole());
      }
    }
  }
}

Fixed version (ground truth):
@Test public void testAssociationSet() throws XMLStreamException, EntityProviderException {
  EdmParser parser=new EdmParser();
  XMLStreamReader reader=createStreamReader(xmlWithAssociation);
  DataServices result=parser.readMetadata(reader,true);
  for (  Schema schema : result.getSchemas()) {
    for (    EntityContainer container : schema.getEntityContainers()) {
      assertEquals(NAMESPACE2,schema.getNamespace());
      assertEquals("String_Node_Str",container.getName());
      assertEquals(Boolean.TRUE,container.isDefaultEntityContainer());
      for (      AssociationSet assocSet : container.getAssociationSets()) {
        assertEquals(ASSOCIATION,assocSet.getName());
        assertEquals(ASSOCIATION,assocSet.getAssociation().getName());
        assertEquals(NAMESPACE,assocSet.getAssociation().getNamespace());
        AssociationSetEnd end;
        if ("String_Node_Str".equals(assocSet.getEnd1().getEntitySet())) {
          end=assocSet.getEnd1();
        }
 else {
          end=assocSet.getEnd2();
        }
        assertEquals("String_Node_Str",end.getRole());
      }
    }
  }
}
Program: 17878
Project: 17878
Buggy source:
private boolean checkForLiteral(final int oldPosition,final char curCharacter,final String rem_expr){
  final Pattern OTHER_LIT=Pattern.compile("String_Node_Str");
  final Matcher matcher=OTHER_LIT.matcher(rem_expr);
  if (matcher.lookingAt()) {
    String token=matcher.group();
    try {
      EdmLiteral edmLiteral=typeDectector.parseUriLiteral(token);
      curPosition+=token.length();
      tokens.appendEdmTypedToken(oldPosition,TokenKind.SIMPLE_TYPE,token,edmLiteral);
      return true;
    }
 catch (    EdmLiteralException e) {
    }
    if (curCharacter == '-') {
      curPosition=curPosition + 1;
      tokens.appendToken(oldPosition,TokenKind.SYMBOL,curCharacter);
      return true;
    }
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean checkForLiteral(final int oldPosition,final char curCharacter,final String rem_expr){
  final Matcher matcher=OTHER_LIT.matcher(rem_expr);
  boolean isLiteral=false;
  if (matcher.lookingAt()) {
    String token=matcher.group();
    try {
      EdmLiteral edmLiteral=typeDectector.parseUriLiteral(token);
      curPosition=curPosition + token.length();
      tokens.appendEdmTypedToken(oldPosition,TokenKind.SIMPLE_TYPE,token,edmLiteral);
      isLiteral=true;
    }
 catch (    EdmLiteralException e) {
      if (curCharacter == '-') {
        curPosition=curPosition + 1;
        tokens.appendToken(oldPosition,TokenKind.SYMBOL,curCharacter);
        isLiteral=true;
      }
 else {
        curPosition=curPosition + token.length();
        tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
        isLiteral=true;
      }
    }
  }
  return isLiteral;
}
Program: 17879
Project: 17879
Buggy source:
private boolean checkForMethod(final int oldPosition,final String rem_expr){
  final Pattern FUNK=Pattern.compile("String_Node_Str");
  Matcher matcher=FUNK.matcher(rem_expr);
  if (matcher.find()) {
    String token=matcher.group(1);
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean checkForMethod(final int oldPosition,final String rem_expr){
  boolean isMethod=false;
  Matcher matcher=FUNK.matcher(rem_expr);
  if (matcher.find()) {
    String token=matcher.group(1);
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    isMethod=true;
  }
  return isMethod;
}
Program: 17880
Project: 17880
Buggy source:
private boolean checkForBinary(final int oldPosition,final String rem_expr){
  final Pattern AND_SUB=Pattern.compile("String_Node_Str");
  Matcher matcher1=AND_SUB.matcher(rem_expr);
  if (matcher1.find()) {
    String token=matcher1.group(1);
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean checkForBinary(final int oldPosition,final String rem_expr){
  boolean isBinary=false;
  Matcher matcher1=AND_SUB.matcher(rem_expr);
  if (matcher1.find()) {
    String token=matcher1.group(1);
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    isBinary=true;
  }
  return isBinary;
}
Program: 17881
Project: 17881
Buggy source:
private boolean checkForPrefix(final String rem_expr) throws ExpressionParserException, TokenizerException {
  final Pattern prefix=Pattern.compile("String_Node_Str");
  Matcher matcher=prefix.matcher(rem_expr);
  String token="String_Node_Str";
  char curCharacter;
  if (matcher.find()) {
    token=matcher.group(1);
    curPosition=curPosition + token.length();
    curCharacter=expression.charAt(curPosition);
    readLiteral(curCharacter,token);
    return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean checkForPrefix(final String rem_expr) throws ExpressionParserException, TokenizerException {
  boolean isPrefix=false;
  Matcher matcher=prefix.matcher(rem_expr);
  String token="String_Node_Str";
  char curCharacter;
  if (matcher.find()) {
    token=matcher.group(1);
    curPosition=curPosition + token.length();
    curCharacter=expression.charAt(curPosition);
    readLiteral(curCharacter,token);
    isPrefix=true;
  }
  return isPrefix;
}
Program: 17882
Project: 17882
Buggy source:
/** 
 * Read up to single ' and move pointer to the following char and tries a type detection
 * @param curCharacter
 * @param token
 * @throws ExpressionParserException
 * @throws TokenizerException
 */
private void readLiteral(char curCharacter,String token) throws ExpressionParserException, TokenizerException {
  int offsetPos=-token.length();
  int oldPosition=curPosition;
  token+=Character.toString(curCharacter);
  curPosition+=1;
  boolean wasHochkomma=false;
  while (curPosition < expressionLength) {
    curCharacter=expression.charAt(curPosition);
    if (curCharacter != '\'') {
      if (wasHochkomma == true) {
        break;
      }
      token=token + curCharacter;
      wasHochkomma=false;
    }
 else {
      if (wasHochkomma) {
        wasHochkomma=false;
      }
 else {
        wasHochkomma=true;
        token=token + curCharacter;
      }
    }
    curPosition+=1;
  }
  if (!wasHochkomma) {
    throw FilterParserExceptionImpl.createTOKEN_UNDETERMINATED_STRING(oldPosition,expression);
  }
  try {
    EdmLiteral edmLiteral=typeDectector.parseUriLiteral(token);
    tokens.appendEdmTypedToken(oldPosition + offsetPos,TokenKind.SIMPLE_TYPE,token,edmLiteral);
  }
 catch (  EdmLiteralException ex) {
    throw TokenizerException.createTYPEDECTECTION_FAILED_ON_STRING(ex,oldPosition,token);
  }
}

Fixed version (ground truth):
/** 
 * Read up to single ' and move pointer to the following char and tries a type detection
 * @param curCharacter
 * @param token
 * @throws ExpressionParserException
 * @throws TokenizerException
 */
private void readLiteral(char curCharacter,String token) throws ExpressionParserException, TokenizerException {
  int offsetPos=-token.length();
  int oldPosition=curPosition;
  token=token + Character.toString(curCharacter);
  curPosition=curPosition + 1;
  boolean wasApostroph=false;
  while (curPosition < expressionLength) {
    curCharacter=expression.charAt(curPosition);
    if (curCharacter != '\'') {
      if (wasApostroph == true) {
        break;
      }
      token=token + curCharacter;
      wasApostroph=false;
    }
 else {
      if (wasApostroph) {
        wasApostroph=false;
      }
 else {
        wasApostroph=true;
        token=token + curCharacter;
      }
    }
    curPosition=curPosition + 1;
  }
  if (!wasApostroph) {
    throw FilterParserExceptionImpl.createTOKEN_UNDETERMINATED_STRING(oldPosition,expression);
  }
  try {
    EdmLiteral edmLiteral=typeDectector.parseUriLiteral(token);
    tokens.appendEdmTypedToken(oldPosition + offsetPos,TokenKind.SIMPLE_TYPE,token,edmLiteral);
  }
 catch (  EdmLiteralException ex) {
    throw TokenizerException.createTYPEDECTECTION_FAILED_ON_STRING(ex,oldPosition,token);
  }
}
Program: 17883
Project: 17883
Buggy source:
private boolean checkForMath(final int oldPosition,final String rem_expr){
  final Pattern AND_SUB1=Pattern.compile("String_Node_Str");
  Matcher matcher1=AND_SUB1.matcher(rem_expr);
  if (matcher1.find()) {
    String token=matcher1.group(1);
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean checkForMath(final int oldPosition,final String rem_expr){
  boolean isMath=false;
  Matcher matcher1=AND_SUB1.matcher(rem_expr);
  if (matcher1.find()) {
    String token=matcher1.group(1);
    curPosition=curPosition + token.length();
    tokens.appendToken(oldPosition,TokenKind.LITERAL,token);
    isMath=true;
  }
  return isMath;
}
Program: 17884
Project: 17884
Buggy source:
private boolean checkForBoolean(final int oldPosition,final String rem_expr){
  if (rem_expr.equals("String_Node_Str") || rem_expr.equals("String_Node_Str")) {
    curPosition=curPosition + rem_expr.length();
    tokens.appendEdmTypedToken(oldPosition,TokenKind.SIMPLE_TYPE,rem_expr,new EdmLiteral(EdmSimpleTypeFacadeImpl.getEdmSimpleType(EdmSimpleTypeKind.Boolean),rem_expr));
    return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean checkForBoolean(final int oldPosition,final String rem_expr){
  boolean isBoolean=false;
  if (rem_expr.equals("String_Node_Str") || rem_expr.equals("String_Node_Str")) {
    curPosition=curPosition + rem_expr.length();
    tokens.appendEdmTypedToken(oldPosition,TokenKind.SIMPLE_TYPE,rem_expr,new EdmLiteral(EdmSimpleTypeFacadeImpl.getEdmSimpleType(EdmSimpleTypeKind.Boolean),rem_expr));
    isBoolean=true;
  }
  return isBoolean;
}
Program: 17885
Project: 17885
Buggy source:
private ODataErrorCallback getErrorHandlerCallbackFromContext(final ODataContext context) throws ClassNotFoundException, InstantiationException, IllegalAccessException {
  ODataErrorCallback callback=null;
  ODataServiceFactory serviceFactory=context.getServiceFactory();
  if (serviceFactory != null) {
    callback=serviceFactory.getCallback(ODataErrorCallback.class);
  }
  return callback;
}

Fixed version (ground truth):
private ODataErrorCallback getErrorHandlerCallbackFromContext(final ODataContext context) throws ClassNotFoundException, InstantiationException, IllegalAccessException {
  ODataErrorCallback callback=null;
  ODataServiceFactory serviceFactory=context.getServiceFactory();
  callback=serviceFactory.getCallback(ODataErrorCallback.class);
  return callback;
}
Program: 17886
Project: 17886
Buggy source:
private ODataContextImpl buildODataContext(final ODataRequest request){
  ODataContextImpl context=new ODataContextImpl();
  context.setRequest(request);
  context.setPathInfo(request.getPathInfo());
  context.setHttpMethod(request.getMethod().name());
  context.setAcceptableLanguages(request.getAcceptableLanguages());
  return context;
}

Fixed version (ground truth):
private ODataContextImpl buildODataContext(final ODataRequest request){
  ODataContextImpl context=new ODataContextImpl();
  context.setServiceFactory(serviceFactory);
  context.setRequest(request);
  context.setPathInfo(request.getPathInfo());
  context.setHttpMethod(request.getMethod().name());
  context.setAcceptableLanguages(request.getAcceptableLanguages());
  return context;
}
Program: 17887
Project: 17887
Buggy source:
private Response returnNotImplementedResponse(final MessageReference messageReference){
  ODataContextImpl context=new ODataContextImpl();
  context.setRequest(request);
  context.setAcceptableLanguages(request.getAcceptableLanguages());
  context.setPathInfo(request.getPathInfo());
  ODataExceptionWrapper exceptionWrapper=new ODataExceptionWrapper(context,request.getQueryParameters(),request.getAcceptHeaders());
  ODataResponse response=exceptionWrapper.wrapInExceptionResponse(new ODataNotImplementedException(messageReference));
  return RestUtil.convertResponse(response);
}

Fixed version (ground truth):
private Response returnNotImplementedResponse(final MessageReference messageReference){
  ODataContextImpl context=new ODataContextImpl();
  context.setRequest(request);
  context.setAcceptableLanguages(request.getAcceptableLanguages());
  context.setPathInfo(request.getPathInfo());
  context.setServiceFactory(serviceFactory);
  ODataExceptionWrapper exceptionWrapper=new ODataExceptionWrapper(context,request.getQueryParameters(),request.getAcceptHeaders());
  ODataResponse response=exceptionWrapper.wrapInExceptionResponse(new ODataNotImplementedException(messageReference));
  return RestUtil.convertResponse(response);
}
Program: 17888
Project: 17888
Buggy source:
public void initialize(final SubLocatorParameter param) throws ODataException {
  requestHandler=new ODataRequestHandler(param.getServiceFactory());
  request=new ODataRequestImpl();
  request.setHeaders(RestUtil.extractRequestHeaders(param.getHttpHeaders()));
  request.setPathInfo(RestUtil.buildODataPathInfo(param));
  request.setBody(RestUtil.contentAsStream(RestUtil.extractRequestContent(param)));
  request.setQueryParameters(RestUtil.convertToSinglevaluedMap(param.getUriInfo().getQueryParameters()));
  request.setAcceptHeaders(RestUtil.extractAcceptHeaders(param));
  request.setContentType(RestUtil.extractRequestContentType(param));
  request.setAcceptableLanguages(param.getHttpHeaders().getAcceptableLanguages());
}

Fixed version (ground truth):
public void initialize(final SubLocatorParameter param) throws ODataException {
  serviceFactory=param.getServiceFactory();
  requestHandler=new ODataRequestHandler(serviceFactory);
  request=new ODataRequestImpl();
  request.setHeaders(RestUtil.extractRequestHeaders(param.getHttpHeaders()));
  request.setPathInfo(RestUtil.buildODataPathInfo(param));
  request.setBody(RestUtil.contentAsStream(RestUtil.extractRequestContent(param)));
  request.setQueryParameters(RestUtil.convertToSinglevaluedMap(param.getUriInfo().getQueryParameters()));
  request.setAcceptHeaders(RestUtil.extractAcceptHeaders(param));
  request.setContentType(RestUtil.extractRequestContentType(param));
  request.setAcceptableLanguages(param.getHttpHeaders().getAcceptableLanguages());
}
Program: 17889
Project: 17889
Buggy source:
public static Map<String,String> extractRequestHeaders(final javax.ws.rs.core.HttpHeaders httpHeaders){
  final MultivaluedMap<String,String> headers=httpHeaders.getRequestHeaders();
  Map<String,String> headerMap=new HashMap<String,String>();
  for (  final String key : headers.keySet()) {
    final String value=httpHeaders.getHeaderString(key);
    if (value != null && !"String_Node_Str".equals(value)) {
      headerMap.put(key,value);
    }
  }
  return headerMap;
}

Fixed version (ground truth):
public static Map<String,String> extractRequestHeaders(final javax.ws.rs.core.HttpHeaders httpHeaders){
  final MultivaluedMap<String,String> headers=httpHeaders.getRequestHeaders();
  Map<String,String> headerMap=new HashMap<String,String>();
  for (  final String key : headers.keySet()) {
    List<String> header=httpHeaders.getRequestHeader(key);
    if (header != null && !header.isEmpty()) {
      String value=header.get(0);
      if (value != null && !"String_Node_Str".equals(value)) {
        headerMap.put(key,value);
      }
    }
  }
  return headerMap;
}
Program: 17890
Project: 17890
Buggy source:
@Override public boolean equals(final Object obj){
  if (this == obj) {
    return true;
  }
  if (obj == null) {
    return false;
  }
  if (getClass() != obj.getClass()) {
    return false;
  }
  MessageReference other=(MessageReference)obj;
  if (key == null) {
    if (other.key != null) {
      return false;
    }
  }
 else   if (!key.equals(other.key)) {
    return false;
  }
  return true;
}

Fixed version (ground truth):
/** 
 * {@link MessageReference}s are equal if their message keys have the same value.
 * @return <code>true</code> if both instances are equal, otherwise <code>false</code>.
 */
@Override public boolean equals(final Object obj){
  if (this == obj) {
    return true;
  }
  if (obj == null) {
    return false;
  }
  if (getClass() != obj.getClass()) {
    return false;
  }
  MessageReference other=(MessageReference)obj;
  if (key == null) {
    if (other.key != null) {
      return false;
    }
  }
 else   if (!key.equals(other.key)) {
    return false;
  }
  return true;
}
Program: 17891
Project: 17891
Buggy source:
@Override public EdmEntityContainer getEntityContainer(final String name) throws EdmException {
  if (edmEntityContainers.containsKey(name)) {
    return edmEntityContainers.get(name);
  }
  EdmEntityContainer edmEntityContainer=null;
  try {
    edmEntityContainer=createEntityContainer(name);
    if (edmEntityContainer != null) {
      if (name == null && edmEntityContainers.containsKey(edmEntityContainer.getName())) {
        edmEntityContainer=edmEntityContainers.get(edmEntityContainer.getName());
        edmEntityContainers.put(name,edmEntityContainer);
      }
 else       if (edmEntityContainers.containsKey(null) && name.equals(edmEntityContainers.get(null).getName())) {
        edmEntityContainer=edmEntityContainers.get(null);
        edmEntityContainers.put(name,edmEntityContainer);
      }
 else {
        edmEntityContainers.put(name,edmEntityContainer);
      }
    }
  }
 catch (  ODataException e) {
    throw new EdmException(EdmException.COMMON,e);
  }
  return edmEntityContainer;
}

Fixed version (ground truth):
@Override public EdmEntityContainer getEntityContainer(final String name) throws EdmException {
  if (edmEntityContainers.containsKey(name)) {
    return edmEntityContainers.get(name);
  }
  EdmEntityContainer edmEntityContainer=null;
  try {
    edmEntityContainer=createEntityContainer(name);
    if (edmEntityContainer != null) {
      if (name == null && edmEntityContainers.containsKey(edmEntityContainer.getName())) {
        edmEntityContainer=edmEntityContainers.get(edmEntityContainer.getName());
        edmEntityContainers.put(name,edmEntityContainer);
      }
 else       if (edmEntityContainers.containsKey(null) && edmEntityContainers.get(null) != null && name.equals(edmEntityContainers.get(null).getName())) {
        edmEntityContainer=edmEntityContainers.get(null);
        edmEntityContainers.put(name,edmEntityContainer);
      }
 else {
        edmEntityContainers.put(name,edmEntityContainer);
      }
    }
  }
 catch (  ODataException e) {
    throw new EdmException(EdmException.COMMON,e);
  }
  return edmEntityContainer;
}
Program: 17892
Project: 17892
Buggy source:
private ServiceDocumentImpl readServiceDocument(final JsonReader reader) throws EntityProviderException {
  try {
    reader.beginObject();
    currentHandledObjectName=reader.nextName();
    if (FormatJson.D.equals(currentHandledObjectName)) {
      reader.beginObject();
      readContent(reader);
      reader.endObject();
    }
    reader.endObject();
    reader.peek();
    reader.close();
  }
 catch (  final IOException e) {
    throw new EntityProviderException(EntityProviderException.COMMON,e);
  }
catch (  final IllegalStateException e) {
    throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
  }
catch (  final EdmException e) {
    throw new EntityProviderException(EntityProviderException.COMMON,e);
  }
catch (  final ODataException e) {
    throw new EntityProviderException(EntityProviderException.COMMON,e);
  }
  return new ServiceDocumentImpl().setEntitySetsInfo(entitySets);
}

Fixed version (ground truth):
private ServiceDocumentImpl readServiceDocument(final JsonReader reader) throws EntityProviderException {
  try {
    reader.beginObject();
    currentHandledObjectName=reader.nextName();
    if (FormatJson.D.equals(currentHandledObjectName)) {
      reader.beginObject();
      readContent(reader);
      reader.endObject();
    }
    reader.endObject();
    reader.peek();
    reader.close();
  }
 catch (  final IOException e) {
    throw new EntityProviderException(EntityProviderException.COMMON,e);
  }
catch (  final IllegalStateException e) {
    throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"),e);
  }
catch (  final EdmException e) {
    throw new EntityProviderException(EntityProviderException.COMMON,e);
  }
catch (  final ODataException e) {
    throw new EntityProviderException(EntityProviderException.COMMON,e);
  }
  return new ServiceDocumentImpl().setEntitySetsInfo(entitySets);
}
Program: 17893
Project: 17893
Buggy source:
@SuppressWarnings("String_Node_Str") private void failContentTypeCreation(final String contentType,final Class<? extends Throwable> expectedExceptionClass) throws Throwable {
  try {
    ContentType mt=ContentType.create(contentType);
    Assert.fail("String_Node_Str" + expectedExceptionClass + "String_Node_Str"+ contentType+ "String_Node_Str");
  }
 catch (  Throwable e) {
    if (e.getClass() == AssertionError.class) {
      throw e;
    }
    assertEquals(expectedExceptionClass,e.getClass());
  }
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private void failContentTypeCreation(final String contentType,final Class<? extends Throwable> expectedExceptionClass) throws Exception {
  try {
    ContentType mt=ContentType.create(contentType);
    Assert.fail("String_Node_Str" + expectedExceptionClass + "String_Node_Str"+ contentType+ "String_Node_Str");
  }
 catch (  Exception e) {
    assertEquals(expectedExceptionClass,e.getClass());
  }
}
Program: 17895
Project: 17895
Buggy source:
private XMLStreamReader createStreamReader(final InputStream in) throws EntityProviderException {
  if (in != null) {
    XMLInputFactory factory=XMLInputFactory.newInstance();
    factory.setProperty(XMLInputFactory.IS_VALIDATING,false);
    factory.setProperty(XMLInputFactory.IS_NAMESPACE_AWARE,true);
    XMLStreamReader streamReader;
    try {
      streamReader=factory.createXMLStreamReader(in);
    }
 catch (    XMLStreamException e) {
      throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
    }
    return streamReader;
  }
 else {
    throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
  }
}

Fixed version (ground truth):
private XMLStreamReader createStreamReader(final InputStream in) throws EntityProviderException {
  if (in != null) {
    XMLInputFactory factory=XMLInputFactory.newInstance();
    factory.setProperty(XMLInputFactory.IS_VALIDATING,false);
    factory.setProperty(XMLInputFactory.IS_NAMESPACE_AWARE,true);
    XMLStreamReader streamReader;
    try {
      streamReader=factory.createXMLStreamReader(in);
    }
 catch (    XMLStreamException e) {
      throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"),e);
    }
    return streamReader;
  }
 else {
    throw new EntityProviderException(EntityProviderException.COMMON.addContent("String_Node_Str"));
  }
}
Program: 17896
Project: 17896
Buggy source:
@SuppressWarnings("String_Node_Str") private void failContentTypeCreation(final String contentType,final Class<? extends Throwable> expectedExceptionClass) throws Exception {
  try {
    ContentType mt=ContentType.create(contentType);
    Assert.fail("String_Node_Str" + expectedExceptionClass + "String_Node_Str"+ contentType+ "String_Node_Str");
  }
 catch (  Exception e) {
    assertEquals(expectedExceptionClass,e.getClass());
  }
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private void failContentTypeCreation(final String contentType,final Class<? extends Exception> expectedExceptionClass) throws Exception {
  try {
    ContentType mt=ContentType.create(contentType);
    Assert.fail("String_Node_Str" + expectedExceptionClass + "String_Node_Str"+ contentType+ "String_Node_Str");
  }
 catch (  Exception e) {
    assertEquals(expectedExceptionClass,e.getClass());
  }
}
Program: 17897
Project: 17897
Buggy source:
@Test public void testODataContextedCauseLayer3(){
  ODataException exception=new ODataException("String_Node_Str",new IllegalArgumentException(new ODataNotFoundException(ODataNotFoundException.ENTITY)));
  Assert.assertTrue(exception.isCausedByHttpException());
}

Fixed version (ground truth):
@Test public void testODataContextedCauseLayer3(){
  ODataException exception=new ODataException("String_Node_Str",new IllegalArgumentException(new ODataNotFoundException(ODataNotFoundException.ENTITY)));
  assertTrue(exception.isCausedByHttpException());
}
Program: 17898
Project: 17898
Buggy source:
@Test public void testODataContextedCause(){
  ODataException exception=new ODataException("String_Node_Str",new ODataNotFoundException(ODataNotFoundException.ENTITY));
  Assert.assertTrue(exception.isCausedByHttpException());
}

Fixed version (ground truth):
@Test public void testODataContextedCause(){
  ODataException exception=new ODataException("String_Node_Str",new ODataNotFoundException(ODataNotFoundException.ENTITY));
  assertTrue(exception.isCausedByHttpException());
}
Program: 17899
Project: 17899
Buggy source:
@Test public void testNoCause(){
  ODataException exception=new ODataException("String_Node_Str");
  Assert.assertFalse(exception.isCausedByHttpException());
}

Fixed version (ground truth):
@Test public void testNoCause(){
  ODataException exception=new ODataException("String_Node_Str");
  assertFalse(exception.isCausedByHttpException());
}
Program: 17900
Project: 17900
Buggy source:
@Test public void testNPECause(){
  ODataException exception=new ODataException("String_Node_Str",new NullPointerException());
  Assert.assertFalse(exception.isCausedByHttpException());
}

Fixed version (ground truth):
@Test public void testNPECause(){
  ODataException exception=new ODataException("String_Node_Str",new NullPointerException());
  assertFalse(exception.isCausedByHttpException());
}