nus-yam/ex-repair huggingface dataset:
Program: 38907
Project: 38907
Buggy source:
@Override protected CollectionResult<Resource> invoke() throws OpenRDFException {
  TupleQuery query=repCon.prepareTupleQuery(QueryLanguage.SPARQL,createOrphanConceptsQuery());
  Set<Value> connectedConcepts=TupleQueryResultUtil.getValuesForBindingName(query.evaluate(),"String_Node_Str");
  Set<Resource> orphanConcepts=new HashSet<Resource>(involvedConcepts.getResult().getData());
  orphanConcepts.removeAll(connectedConcepts);
  return new CollectionResult<Resource>(orphanConcepts);
}

Fixed version (ground truth):
@Override protected CollectionResult<Resource> invoke() throws OpenRDFException {
  TupleQuery query=repCon.prepareTupleQuery(QueryLanguage.SPARQL,createOrphanConceptsQuery());
  Set<Value> connectedConcepts=TupleQueryResultUtil.getValuesForBindingName(query.evaluate(),"String_Node_Str");
  Set<Resource> orphanConcepts=new HashSet<>(involvedConcepts.getResult().getData());
  orphanConcepts.removeAll(connectedConcepts);
  return new CollectionResult<>(orphanConcepts);
}
Program: 38908
Project: 38908
Buggy source:
@Override protected CollectionResult<Statement> invoke() throws OpenRDFException {
  Collection<Statement> problematicRelations=new ArrayList<Statement>();
  RepositoryResult<Statement> result=repCon.getStatements(null,SkosOntology.getInstance().getUri("String_Node_Str"),null,true);
  while (result.hasNext()) {
    Statement st=result.next();
    Resource concept=st.getSubject();
    Resource otherConcept=(Resource)st.getObject();
    if (areAuthoritativeConcepts(concept,otherConcept) && (ConceptSchemeUtil.inSameConceptScheme(concept,otherConcept,repCon) || ConceptSchemeUtil.inNoConceptScheme(concept,otherConcept,repCon))) {
      problematicRelations.add(st);
    }
  }
  return new CollectionResult<Statement>(problematicRelations);
}

Fixed version (ground truth):
@Override protected CollectionResult<Statement> invoke() throws OpenRDFException {
  Collection<Statement> problematicRelations=new ArrayList<>();
  RepositoryResult<Statement> result=repCon.getStatements(null,SkosOntology.getInstance().getUri("String_Node_Str"),null,true);
  while (result.hasNext()) {
    Statement st=result.next();
    Resource concept=st.getSubject();
    Resource otherConcept=(Resource)st.getObject();
    if (areAuthoritativeConcepts(concept,otherConcept) && (ConceptSchemeUtil.inSameConceptScheme(concept,otherConcept,repCon) || ConceptSchemeUtil.inNoConceptScheme(concept,otherConcept,repCon))) {
      problematicRelations.add(st);
    }
  }
  return new CollectionResult<>(problematicRelations);
}
Program: 38909
Project: 38909
Buggy source:
@Override protected CollectionResult<Resource> invoke() throws OpenRDFException {
  Collection<Resource> csWithOmittedTopConcepts=new HashSet<Resource>();
  for (  Resource conceptScheme : conceptSchemes.getResult().getData()) {
    BooleanQuery hasTopConceptQuery=repCon.prepareBooleanQuery(QueryLanguage.SPARQL,createConceptSchemeWithoutTopConceptQuery(conceptScheme));
    if (!hasTopConceptQuery.evaluate()) {
      csWithOmittedTopConcepts.add(conceptScheme);
    }
  }
  return new CollectionResult<Resource>(csWithOmittedTopConcepts);
}

Fixed version (ground truth):
@Override protected CollectionResult<Resource> invoke() throws OpenRDFException {
  Collection<Resource> csWithOmittedTopConcepts=new HashSet<>();
  for (  Resource conceptScheme : conceptSchemes.getResult().getData()) {
    BooleanQuery hasTopConceptQuery=repCon.prepareBooleanQuery(QueryLanguage.SPARQL,createConceptSchemeWithoutTopConceptQuery(conceptScheme));
    if (!hasTopConceptQuery.evaluate()) {
      csWithOmittedTopConcepts.add(conceptScheme);
    }
  }
  return new CollectionResult<>(csWithOmittedTopConcepts);
}
Program: 38910
Project: 38910
Buggy source:
private Collection<Value> createUriResultList(TupleQueryResult result) throws OpenRDFException {
  List<Value> resultList=new ArrayList<Value>();
  while (result.hasNext()) {
    BindingSet queryResult=result.next();
    URI resource=(URI)queryResult.getValue("String_Node_Str");
    resultList.add(resource);
  }
  return resultList;
}

Fixed version (ground truth):
private Collection<Value> createUriResultList(TupleQueryResult result) throws OpenRDFException {
  List<Value> resultList=new ArrayList<>();
  while (result.hasNext()) {
    BindingSet queryResult=result.next();
    URI resource=(URI)queryResult.getValue("String_Node_Str");
    resultList.add(resource);
  }
  return resultList;
}
Program: 38911
Project: 38911
Buggy source:
@Override protected CollectionResult<Value> invoke() throws OpenRDFException {
  TupleQuery query=repCon.prepareTupleQuery(QueryLanguage.SPARQL,createTopConceptsHavingBroaderConceptQuery());
  return new CollectionResult<Value>(createUriResultList(query.evaluate()));
}

Fixed version (ground truth):
@Override protected CollectionResult<Value> invoke() throws OpenRDFException {
  TupleQuery query=repCon.prepareTupleQuery(QueryLanguage.SPARQL,createTopConceptsHavingBroaderConceptQuery());
  return new CollectionResult<>(createUriResultList(query.evaluate()));
}
Program: 38912
Project: 38912
Buggy source:
private List<Collection<Resource>> trackNodesInCycles(Set<Resource> nodesInCycles){
  List<Collection<Resource>> ret=new ArrayList<Collection<Resource>>();
  List<Set<Resource>> stronglyConnectedSets=new StrongConnectivityInspector<Resource,NamedEdge>(hierarchyGraph).stronglyConnectedSets();
  for (  Resource node : nodesInCycles) {
    for (    Set<Resource> stronglyConnectedSet : stronglyConnectedSets) {
      if (stronglyConnectedSet.contains(node)) {
        if (!ret.contains(stronglyConnectedSet)) {
          ret.add(stronglyConnectedSet);
        }
      }
    }
  }
  return ret;
}

Fixed version (ground truth):
private List<Collection<Resource>> trackNodesInCycles(Set<Resource> nodesInCycles){
  List<Collection<Resource>> ret=new ArrayList<>();
  List<Set<Resource>> stronglyConnectedSets=new StrongConnectivityInspector<>(hierarchyGraph).stronglyConnectedSets();
  for (  Resource node : nodesInCycles) {
    for (    Set<Resource> stronglyConnectedSet : stronglyConnectedSets) {
      if (stronglyConnectedSet.contains(node)) {
        if (!ret.contains(stronglyConnectedSet)) {
          ret.add(stronglyConnectedSet);
        }
      }
    }
  }
  return ret;
}
Program: 38913
Project: 38913
Buggy source:
private List<Collection<Resource>> findCycleContainingComponents(){
  logger.debug("String_Node_Str");
  Set<Resource> nodesInCycles=new CycleDetector<Resource,NamedEdge>(hierarchyGraph).findCycles();
  return trackNodesInCycles(nodesInCycles);
}

Fixed version (ground truth):
private List<Collection<Resource>> findCycleContainingComponents(){
  logger.debug("String_Node_Str");
  Set<Resource> nodesInCycles=new CycleDetector<>(hierarchyGraph).findCycles();
  return trackNodesInCycles(nodesInCycles);
}
Program: 38914
Project: 38914
Buggy source:
@Override protected ExtrapolatedCollectionResult<Resource> invoke() throws OpenRDFException {
  Collection<Resource> conceptsToCheck=getConceptsToCheck(randomSubsetSize_percent);
  if (randomSubsetSize_percent != null) {
    logger.info("String_Node_Str" + conceptsToCheck.size() + "String_Node_Str");
  }
  Iterator<Resource> conceptIt=new MonitoredIterator<Resource>(conceptsToCheck,progressMonitor,"String_Node_Str");
  while (conceptIt.hasNext()) {
    rankConcept(conceptIt.next());
  }
  return new ExtrapolatedCollectionResult<Resource>(extractUnreferencedConcepts(),randomSubsetSize_percent);
}

Fixed version (ground truth):
@Override protected ExtrapolatedCollectionResult<Resource> invoke() throws OpenRDFException {
  Collection<Resource> conceptsToCheck=getConceptsToCheck(randomSubsetSize_percent);
  if (randomSubsetSize_percent != null) {
    logger.info("String_Node_Str" + conceptsToCheck.size() + "String_Node_Str");
  }
  Iterator<Resource> conceptIt=new MonitoredIterator<>(conceptsToCheck,progressMonitor,"String_Node_Str");
  while (conceptIt.hasNext()) {
    rankConcept(conceptIt.next());
  }
  return new ExtrapolatedCollectionResult<>(extractUnreferencedConcepts(),randomSubsetSize_percent);
}
Program: 38915
Project: 38915
Buggy source:
private Collection<Resource> getConceptsToCheck(Float randomSubsetSize_percent) throws OpenRDFException {
  if (randomSubsetSize_percent == null) {
    return authoritativeConcepts.getResult().getData();
  }
 else {
    return new RandomSubSet<Resource>(authoritativeConcepts.getResult().getData(),randomSubsetSize_percent);
  }
}

Fixed version (ground truth):
private Collection<Resource> getConceptsToCheck(Float randomSubsetSize_percent) throws OpenRDFException {
  if (randomSubsetSize_percent == null) {
    return authoritativeConcepts.getResult().getData();
  }
 else {
    return new RandomSubSet<>(authoritativeConcepts.getResult().getData(),randomSubsetSize_percent);
  }
}
Program: 38916
Project: 38916
Buggy source:
private void addToConceptsRankMap(Resource concept,TupleQueryResult result) throws QueryEvaluationException {
  Set<URI> referencingResourcesOnOtherHost=getReferencingResourcesOnOtherHost(concept,result);
  Set<URI> allReferencingResources=conceptReferencingResources.get(concept);
  if (allReferencingResources == null) {
    allReferencingResources=new HashSet<URI>();
    conceptReferencingResources.put(concept,allReferencingResources);
  }
  allReferencingResources.addAll(referencingResourcesOnOtherHost);
}

Fixed version (ground truth):
private void addToConceptsRankMap(Resource concept,TupleQueryResult result) throws QueryEvaluationException {
  Set<URI> referencingResourcesOnOtherHost=getReferencingResourcesOnOtherHost(concept,result);
  Set<URI> allReferencingResources=conceptReferencingResources.get(concept);
  if (allReferencingResources == null) {
    allReferencingResources=new HashSet<>();
    conceptReferencingResources.put(concept,allReferencingResources);
  }
  allReferencingResources.addAll(referencingResourcesOnOtherHost);
}
Program: 38917
Project: 38917
Buggy source:
private Collection<Resource> extractUnreferencedConcepts(){
  Collection<Resource> unrefConcepts=new HashSet<Resource>();
  for (  Resource concept : conceptReferencingResources.keySet()) {
    if (conceptReferencingResources.get(concept).isEmpty()) {
      unrefConcepts.add(concept);
    }
  }
  return unrefConcepts;
}

Fixed version (ground truth):
private Collection<Resource> extractUnreferencedConcepts(){
  Collection<Resource> unrefConcepts=new HashSet<>();
  for (  Resource concept : conceptReferencingResources.keySet()) {
    if (conceptReferencingResources.get(concept).isEmpty()) {
      unrefConcepts.add(concept);
    }
  }
  return unrefConcepts;
}
Program: 38918
Project: 38918
Buggy source:
private Set<URI> getReferencingResourcesOnOtherHost(Value concept,TupleQueryResult result) throws QueryEvaluationException {
  Set<URI> referencingResourcesOnOtherHost=new HashSet<URI>();
  while (result.hasNext()) {
    Value referencingResource=result.next().getValue("String_Node_Str");
    try {
      if (referencingResource instanceof URI && concept instanceof URI && isDistinctHost((URI)concept,(URI)referencingResource)) {
        referencingResourcesOnOtherHost.add((URI)referencingResource);
      }
    }
 catch (    URISyntaxException e) {
    }
  }
  return referencingResourcesOnOtherHost;
}

Fixed version (ground truth):
private Set<URI> getReferencingResourcesOnOtherHost(Value concept,TupleQueryResult result) throws QueryEvaluationException {
  Set<URI> referencingResourcesOnOtherHost=new HashSet<>();
  while (result.hasNext()) {
    Value referencingResource=result.next().getValue("String_Node_Str");
    try {
      if (referencingResource instanceof URI && concept instanceof URI && isDistinctHost((URI)concept,(URI)referencingResource)) {
        referencingResourcesOnOtherHost.add((URI)referencingResource);
      }
    }
 catch (    URISyntaxException e) {
    }
  }
  return referencingResourcesOnOtherHost;
}
Program: 38919
Project: 38919
Buggy source:
private Collection<URI> collectUrisToBeDereferenced() throws OpenRDFException {
  if (randomSubsetSize_percent == null) {
    return httpURIs.getResult().getData();
  }
  RandomSubSet<URI> urisToBeDereferenced=new RandomSubSet<URI>(httpURIs.getResult().getData(),randomSubsetSize_percent);
  logger.info("String_Node_Str" + urisToBeDereferenced.size() + "String_Node_Str");
  return urisToBeDereferenced;
}

Fixed version (ground truth):
private Collection<URI> collectUrisToBeDereferenced() throws OpenRDFException {
  if (randomSubsetSize_percent == null) {
    return httpURIs.getResult().getData();
  }
  RandomSubSet<URI> urisToBeDereferenced=new RandomSubSet<>(httpURIs.getResult().getData(),randomSubsetSize_percent);
  logger.info("String_Node_Str" + urisToBeDereferenced.size() + "String_Node_Str");
  return urisToBeDereferenced;
}
Program: 38920
Project: 38920
Buggy source:
private void dereferenceURIs() throws OpenRDFException {
  Collection<URI> urisToBeDereferenced=collectUrisToBeDereferenced();
  Iterator<URI> it=new MonitoredIterator<URI>(urisToBeDereferenced,progressMonitor);
  int i=1;
  while (it.hasNext()) {
    URI uri=it.next();
    logger.debug("String_Node_Str" + i + "String_Node_Str"+ urisToBeDereferenced.size());
    i++;
    try {
      Thread.sleep(extAccessDelayMillis);
    }
 catch (    InterruptedException e) {
    }
    addToResults(uri);
  }
}

Fixed version (ground truth):
private void dereferenceURIs() throws OpenRDFException {
  Collection<URI> urisToBeDereferenced=collectUrisToBeDereferenced();
  Iterator<URI> it=new MonitoredIterator<>(urisToBeDereferenced,progressMonitor);
  int i=1;
  while (it.hasNext()) {
    URI uri=it.next();
    logger.debug("String_Node_Str" + i + "String_Node_Str"+ urisToBeDereferenced.size());
    i++;
    try {
      Thread.sleep(extAccessDelayMillis);
    }
 catch (    InterruptedException e) {
    }
    addToResults(uri);
  }
}
Program: 38921
Project: 38921
Buggy source:
@Override protected ExtrapolatedCollectionResult<URL> invoke() throws OpenRDFException {
  dereferenceURIs();
  return new ExtrapolatedCollectionResult<URL>(collectUnavailableURLs(),randomSubsetSize_percent);
}

Fixed version (ground truth):
@Override protected ExtrapolatedCollectionResult<URL> invoke() throws OpenRDFException {
  dereferenceURIs();
  return new ExtrapolatedCollectionResult<>(collectUnavailableURLs(),randomSubsetSize_percent);
}
Program: 38922
Project: 38922
Buggy source:
private Collection<URL> collectUnavailableURLs(){
  Collection<URL> unavailableURLs=new ArrayList<URL>();
  for (  URL url : urlAvailability.keySet()) {
    if (urlAvailability.get(url) == null) {
      unavailableURLs.add(url);
    }
  }
  return unavailableURLs;
}

Fixed version (ground truth):
private Collection<URL> collectUnavailableURLs(){
  Collection<URL> unavailableURLs=new ArrayList<>();
  for (  URL url : urlAvailability.keySet()) {
    if (urlAvailability.get(url) == null) {
      unavailableURLs.add(url);
    }
  }
  return unavailableURLs;
}
Program: 38923
Project: 38923
Buggy source:
@Override protected CollectionResult<URI> invoke() throws OpenRDFException {
  RepositoryResult<Statement> result=repCon.getStatements(null,null,null,false,(Resource)null);
  while (result.hasNext()) {
    Statement st=result.next();
    Collection<Value> tripleValues=new ArrayList<Value>();
    tripleValues.addAll(Arrays.asList(st.getSubject(),st.getObject(),st.getPredicate()));
    for (    Value value : tripleValues) {
      if (value instanceof org.openrdf.model.URI)       addToUrlList(value);
    }
  }
  return new CollectionResult<URI>(httpURIs);
}

Fixed version (ground truth):
@Override protected CollectionResult<URI> invoke() throws OpenRDFException {
  RepositoryResult<Statement> result=repCon.getStatements(null,null,null,false,(Resource)null);
  while (result.hasNext()) {
    Statement st=result.next();
    Collection<Value> tripleValues=new ArrayList<>();
    tripleValues.addAll(Arrays.asList(st.getSubject(),st.getObject(),st.getPredicate()));
    for (    Value value : tripleValues) {
      if (value instanceof org.openrdf.model.URI)       addToUrlList(value);
    }
  }
  return new CollectionResult<>(httpURIs);
}
Program: 38924
Project: 38924
Buggy source:
private Collection<URI> extractExternalResources(Collection<URI> allResources) throws OpenRDFException {
  Collection<URI> validExternalResources=new HashSet<URI>();
  for (  URI uri : allResources) {
    if (isExternalResource(uri) && isNonSkosURL(uri)) {
      validExternalResources.add(uri);
    }
  }
  return validExternalResources;
}

Fixed version (ground truth):
private Collection<URI> extractExternalResources(Collection<URI> allResources) throws OpenRDFException {
  Collection<URI> validExternalResources=new HashSet<>();
  for (  URI uri : allResources) {
    if (isExternalResource(uri) && isNonSkosURL(uri)) {
      validExternalResources.add(uri);
    }
  }
  return validExternalResources;
}
Program: 38925
Project: 38925
Buggy source:
@Override protected CollectionResult<Resource> invoke() throws OpenRDFException {
  extResourcesForConcept=new HashMap<Resource,Collection<URI>>();
  findResourcesForConcepts(authoritativeConcepts.getResult().getData());
  return new CollectionResult<Resource>(extractUnlinkedConcepts());
}

Fixed version (ground truth):
@Override protected CollectionResult<Resource> invoke() throws OpenRDFException {
  extResourcesForConcept=new HashMap<>();
  findResourcesForConcepts(authoritativeConcepts.getResult().getData());
  return new CollectionResult<>(extractUnlinkedConcepts());
}
Program: 38926
Project: 38926
Buggy source:
private void findResourcesForConcepts(Collection<Resource> concepts) throws OpenRDFException {
  Iterator<Resource> conceptIt=new MonitoredIterator<Resource>(concepts,progressMonitor,"String_Node_Str");
  while (conceptIt.hasNext()) {
    Resource concept=conceptIt.next();
    extResourcesForConcept.put(concept,extractExternalResources(getURIsOfConcept(concept)));
  }
}

Fixed version (ground truth):
private void findResourcesForConcepts(Collection<Resource> concepts) throws OpenRDFException {
  Iterator<Resource> conceptIt=new MonitoredIterator<>(concepts,progressMonitor,"String_Node_Str");
  while (conceptIt.hasNext()) {
    Resource concept=conceptIt.next();
    extResourcesForConcept.put(concept,extractExternalResources(getURIsOfConcept(concept)));
  }
}
Program: 38927
Project: 38927
Buggy source:
private Collection<Resource> extractUnlinkedConcepts(){
  Collection<Resource> unlinkedConcepts=new HashSet<Resource>();
  for (  Resource concept : extResourcesForConcept.keySet()) {
    if (extResourcesForConcept.get(concept).isEmpty()) {
      unlinkedConcepts.add(concept);
    }
  }
  return unlinkedConcepts;
}

Fixed version (ground truth):
private Collection<Resource> extractUnlinkedConcepts(){
  Collection<Resource> unlinkedConcepts=new HashSet<>();
  for (  Resource concept : extResourcesForConcept.keySet()) {
    if (extResourcesForConcept.get(concept).isEmpty()) {
      unlinkedConcepts.add(concept);
    }
  }
  return unlinkedConcepts;
}
Program: 38928
Project: 38928
Buggy source:
private Collection<URI> getURIsOfConcept(Resource concept) throws RepositoryException {
  Collection<URI> urisForConcept=new ArrayList<URI>();
  RepositoryResult<Statement> conceptAsSubject=repCon.getStatements((Resource)concept,null,null,false);
  while (conceptAsSubject.hasNext()) {
    Value object=conceptAsSubject.next().getObject();
    addToUriCollection(object,urisForConcept);
  }
  RepositoryResult<Statement> conceptAsObject=repCon.getStatements(null,null,concept,false);
  while (conceptAsObject.hasNext()) {
    Value object=conceptAsObject.next().getSubject();
    addToUriCollection(object,urisForConcept);
  }
  return urisForConcept;
}

Fixed version (ground truth):
private Collection<URI> getURIsOfConcept(Resource concept) throws RepositoryException {
  Collection<URI> urisForConcept=new ArrayList<>();
  RepositoryResult<Statement> conceptAsSubject=repCon.getStatements(concept,null,null,false);
  while (conceptAsSubject.hasNext()) {
    Value object=conceptAsSubject.next().getObject();
    addToUriCollection(object,urisForConcept);
  }
  RepositoryResult<Statement> conceptAsObject=repCon.getStatements(null,null,concept,false);
  while (conceptAsObject.hasNext()) {
    Value object=conceptAsObject.next().getSubject();
    addToUriCollection(object,urisForConcept);
  }
  return urisForConcept;
}
Program: 38929
Project: 38929
Buggy source:
private CollectionResult<Tuple<Resource>> createReport(){
  Collection<Tuple<Resource>> relatedConcepts=new HashSet<Tuple<Resource>>();
  for (  Statement statement : solitaryTransitiveRelations) {
    relatedConcepts.add(new Tuple<Resource>(statement.getSubject(),(Resource)statement.getObject()));
  }
  return new CollectionResult(relatedConcepts);
}

Fixed version (ground truth):
private CollectionResult<Tuple<Resource>> createReport(){
  Collection<Tuple<Resource>> relatedConcepts=new HashSet<>();
  for (  Statement statement : solitaryTransitiveRelations) {
    relatedConcepts.add(new Tuple<>(statement.getSubject(),(Resource)statement.getObject()));
  }
  return new CollectionResult(relatedConcepts);
}
Program: 38930
Project: 38930
Buggy source:
@Override protected CollectionResult<Tuple<Resource>> invoke() throws OpenRDFException {
  solitaryTransitiveRelations=new ArrayList<Statement>();
  for (  String[] transitivePropertyPair : transitiveNontransiviteInverseProperties) {
    String query=createSolitaryTransitiveRelationsQuery(transitivePropertyPair);
    TupleQuery tupleQuery=repCon.prepareTupleQuery(QueryLanguage.SPARQL,query);
    addToResults(tupleQuery.evaluate(),transitivePropertyPair[0]);
  }
  return createReport();
}

Fixed version (ground truth):
@Override protected CollectionResult<Tuple<Resource>> invoke() throws OpenRDFException {
  solitaryTransitiveRelations=new ArrayList<>();
  for (  String[] transitivePropertyPair : transitiveNontransiviteInverseProperties) {
    String query=createSolitaryTransitiveRelationsQuery(transitivePropertyPair);
    TupleQuery tupleQuery=repCon.prepareTupleQuery(QueryLanguage.SPARQL,query);
    addToResults(tupleQuery.evaluate(),transitivePropertyPair[0]);
  }
  return createReport();
}
Program: 38931
Project: 38931
Buggy source:
private void addStatisticalIssues(){
  involvedConcepts=new InvolvedConcepts();
  authoritativeConcepts=new AuthoritativeConcepts(involvedConcepts);
  authoritativeConcepts.setBaseURI(baseURI);
  authoritativeConcepts.setAuthResourceIdentifier(authResourceIdentifier);
  conceptSchemes=new ConceptSchemes();
  httpURIs=new HttpURIs();
  registeredIssues.add(involvedConcepts);
  registeredIssues.add(authoritativeConcepts);
  registeredIssues.add(new LexicalRelations(involvedConcepts));
  registeredIssues.add(new SemanticRelations());
  registeredIssues.add(new AggregationRelations());
  registeredIssues.add(conceptSchemes);
  registeredIssues.add(new at.ac.univie.mminf.qskos4j.issues.count.Collections());
  registeredIssues.add(httpURIs);
}

Fixed version (ground truth):
private void addStatisticalIssues(){
  involvedConcepts=new InvolvedConcepts();
  authoritativeConcepts=new AuthoritativeConcepts(involvedConcepts);
  authoritativeConcepts.setBaseURI(baseURI);
  conceptSchemes=new ConceptSchemes();
  httpURIs=new HttpURIs();
  registeredIssues.add(involvedConcepts);
  registeredIssues.add(authoritativeConcepts);
  registeredIssues.add(new LexicalRelations(involvedConcepts));
  registeredIssues.add(new SemanticRelations());
  registeredIssues.add(new AggregationRelations());
  registeredIssues.add(conceptSchemes);
  registeredIssues.add(new at.ac.univie.mminf.qskos4j.issues.count.Collections());
  registeredIssues.add(httpURIs);
}
Program: 38932
Project: 38932
Buggy source:
/** 
 * Some methods in this class support investigating only a subset of the vocabulary and extrapolate the results to shorten evaluation time. Works for, e.g., finding broken links. 
 * @param subsetSizePercent percentage of the total resources to investigate.
 */
public void setSubsetSize(Float subsetSizePercent){
  randomSubsetSize_percent=subsetSizePercent;
}

Fixed version (ground truth):
/** 
 * Some methods in this class support investigating only a subset of the vocabulary and extrapolate the results to shorten evaluation time. Works for, e.g., finding broken links. 
 * @param subsetSizePercent percentage of the total resources to investigate.
 */
public void setSubsetSize(Float subsetSizePercent){
  missingInLinks.setSubsetSize(subsetSizePercent);
  brokenLinks.setSubsetSize(subsetSizePercent);
}
Program: 38933
Project: 38933
Buggy source:
private void addAnalyticalIssues(){
  HierarchyGraphBuilder hierarchyGraphBuilder=new HierarchyGraphBuilder();
  registeredIssues.add(new OmittedOrInvalidLanguageTags());
  registeredIssues.add(new IncompleteLanguageCoverage(involvedConcepts));
  registeredIssues.add(new UndocumentedConcepts(authoritativeConcepts));
  registeredIssues.add(new OverlappingLabels(involvedConcepts));
  registeredIssues.add(new OrphanConcepts(involvedConcepts));
  registeredIssues.add(new DisconnectedConceptClusters(involvedConcepts));
  registeredIssues.add(new HierarchicalCycles(hierarchyGraphBuilder));
  registeredIssues.add(new ValuelessAssociativeRelations());
  registeredIssues.add(new SolelyTransitivelyRelatedConcepts());
  registeredIssues.add(new OmittedTopConcepts(conceptSchemes));
  registeredIssues.add(new TopConceptsHavingBroaderConcepts());
  missingInLinks=new MissingInLinks(authoritativeConcepts);
  missingInLinks.setQueryDelayMillis(extAccessDelayMillis);
  missingInLinks.setSubsetSize(randomSubsetSize_percent);
  registeredIssues.add(missingInLinks);
  registeredIssues.add(new MissingOutLinks(authoritativeConcepts));
  BrokenLinks brokenLinks=new BrokenLinks(httpURIs);
  brokenLinks.setSubsetSize(randomSubsetSize_percent);
  brokenLinks.setExtAccessDelayMillis(extAccessDelayMillis);
  registeredIssues.add(brokenLinks);
  registeredIssues.add(new UndefinedSkosResources());
  registeredIssues.add(new UnidirectionallyRelatedConcepts());
  registeredIssues.add(new HttpUriSchemeViolations());
  registeredIssues.add(new RelationClashes(hierarchyGraphBuilder));
  registeredIssues.add(new MappingClashes());
}

Fixed version (ground truth):
private void addAnalyticalIssues(){
  HierarchyGraphBuilder hierarchyGraphBuilder=new HierarchyGraphBuilder();
  registeredIssues.add(new OmittedOrInvalidLanguageTags());
  registeredIssues.add(new IncompleteLanguageCoverage(involvedConcepts));
  registeredIssues.add(new UndocumentedConcepts(authoritativeConcepts));
  registeredIssues.add(new OverlappingLabels(involvedConcepts));
  registeredIssues.add(new OrphanConcepts(involvedConcepts));
  registeredIssues.add(new DisconnectedConceptClusters(involvedConcepts));
  registeredIssues.add(new HierarchicalCycles(hierarchyGraphBuilder));
  registeredIssues.add(new ValuelessAssociativeRelations());
  registeredIssues.add(new SolelyTransitivelyRelatedConcepts());
  registeredIssues.add(new OmittedTopConcepts(conceptSchemes));
  registeredIssues.add(new TopConceptsHavingBroaderConcepts());
  missingInLinks=new MissingInLinks(authoritativeConcepts);
  missingInLinks.setQueryDelayMillis(EXT_ACCESS_MILLIS);
  registeredIssues.add(missingInLinks);
  registeredIssues.add(new MissingOutLinks(authoritativeConcepts));
  brokenLinks=new BrokenLinks(httpURIs);
  brokenLinks.setExtAccessDelayMillis(EXT_ACCESS_MILLIS);
  registeredIssues.add(brokenLinks);
  registeredIssues.add(new UndefinedSkosResources());
  registeredIssues.add(new UnidirectionallyRelatedConcepts());
  registeredIssues.add(new HttpUriSchemeViolations());
  registeredIssues.add(new RelationClashes(hierarchyGraphBuilder));
  registeredIssues.add(new MappingClashes());
}
Program: 38934
Project: 38934
Buggy source:
/** 
 * Sets a string that is used to identify if an URI is authoritative. This is required to, e.g., find all out-links to distinguish between URIs in the vocabulary namespace and other resources on the Web.
 * @param authResourceIdentifier a string, usually a substring of an URI in the vocabulary's namespace,that uniquely identifies an authoritative URI.
 */
public void setAuthResourceIdentifier(String authResourceIdentifier){
  this.authResourceIdentifier=authResourceIdentifier;
}

Fixed version (ground truth):
/** 
 * Sets a string that is used to identify if an URI is authoritative. This is required to, e.g., find all out-links to distinguish between URIs in the vocabulary namespace and other resources on the Web.
 * @param authResourceIdentifier a string, usually a substring of an URI in the vocabulary's namespace,that uniquely identifies an authoritative URI.
 */
public void setAuthResourceIdentifier(String authResourceIdentifier){
  authoritativeConcepts.setAuthResourceIdentifier(authResourceIdentifier);
}
Program: 38935
Project: 38935
Buggy source:
/** 
 * Sets a delay time in milliseconds that must pass between accessing an external resource. This is intended to avoid flooding of, e.g., vocabulary hosts or SPARQL endpoints with HTTP requests.
 * @param delayMillis delay time in milliseconds
 */
@SuppressWarnings("String_Node_Str") public void setExtAccessDelayMillis(int delayMillis){
  extAccessDelayMillis=delayMillis;
}

Fixed version (ground truth):
/** 
 * Sets a delay time in milliseconds that must pass between accessing an external resource. This is intended to avoid flooding of, e.g., vocabulary hosts or SPARQL endpoints with HTTP requests.
 * @param delayMillis delay time in milliseconds
 */
@SuppressWarnings("String_Node_Str") public void setExtAccessDelayMillis(int delayMillis){
  missingInLinks.setQueryDelayMillis(delayMillis);
  brokenLinks.setExtAccessDelayMillis(delayMillis);
}
Program: 38936
Project: 38936
Buggy source:
public DisjointLabelsViolations(ResourceLabelsCollector resourceLabelsCollector){
  super(resourceLabelsCollector,"String_Node_Str","String_Node_Str","String_Node_Str",IssueType.ANALYTICAL);
  this.resourceLabelsCollector=resourceLabelsCollector;
}

Fixed version (ground truth):
public DisjointLabelsViolations(ResourceLabelsCollector resourceLabelsCollector){
  super("String_Node_Str","String_Node_Str","String_Node_Str",IssueType.ANALYTICAL);
  this.resourceLabelsCollector=resourceLabelsCollector;
}
Program: 38937
Project: 38937
Buggy source:
private Map<Literal,Collection<LabeledConcept>> orderResourcesByLabel() throws OpenRDFException {
  Map<Literal,Collection<LabeledConcept>> resourcesByLabel=new HashMap<Literal,Collection<LabeledConcept>>();
  for (  LabeledConcept labeledResource : resourceLabelsCollector.getPreparedData()) {
    Literal literal=new LiteralImpl(labeledResource.getLiteral().getLabel().toUpperCase(),labeledResource.getLiteral().getLanguage());
    Collection<LabeledConcept> resourcesForLiteral=resourcesByLabel.get(literal);
    if (resourcesForLiteral == null) {
      resourcesForLiteral=new HashSet<LabeledConcept>();
      resourcesByLabel.put(literal,resourcesForLiteral);
    }
    resourcesForLiteral.add(labeledResource);
  }
  return resourcesByLabel;
}

Fixed version (ground truth):
private Map<Literal,Collection<LabeledConcept>> orderResourcesByLabel() throws OpenRDFException {
  Map<Literal,Collection<LabeledConcept>> resourcesByLabel=new HashMap<Literal,Collection<LabeledConcept>>();
  for (  LabeledConcept labeledResource : resourceLabelsCollector.getLabeledConcepts()) {
    Literal literal=new LiteralImpl(labeledResource.getLiteral().getLabel().toUpperCase(),labeledResource.getLiteral().getLanguage());
    Collection<LabeledConcept> resourcesForLiteral=resourcesByLabel.get(literal);
    if (resourcesForLiteral == null) {
      resourcesForLiteral=new HashSet<LabeledConcept>();
      resourcesByLabel.put(literal,resourcesForLiteral);
    }
    resourcesForLiteral.add(labeledResource);
  }
  return resourcesByLabel;
}
Program: 38938
Project: 38938
Buggy source:
private Map<Value,Collection<LabeledConcept>> orderPrefLabelsByResource() throws OpenRDFException {
  Map<Value,Collection<LabeledConcept>> prefLabelsByResource=new HashMap<Value,Collection<LabeledConcept>>();
  for (  LabeledConcept labeledConcept : resourceLabelsCollector.getPreparedData()) {
    if (labeledConcept.getLabelType() != LabelType.PREF_LABEL)     continue;
    Collection<LabeledConcept> labeledResourcesOfUri=prefLabelsByResource.get(labeledConcept.getConcept());
    if (labeledResourcesOfUri == null) {
      labeledResourcesOfUri=new ArrayList<LabeledConcept>();
      prefLabelsByResource.put(labeledConcept.getConcept(),labeledResourcesOfUri);
    }
    labeledResourcesOfUri.add(labeledConcept);
  }
  return prefLabelsByResource;
}

Fixed version (ground truth):
private Map<Value,Collection<LabeledConcept>> orderPrefLabelsByResource() throws OpenRDFException {
  Map<Value,Collection<LabeledConcept>> prefLabelsByResource=new HashMap<Value,Collection<LabeledConcept>>();
  for (  LabeledConcept labeledConcept : resourceLabelsCollector.getLabeledConcepts()) {
    if (labeledConcept.getLabelType() != LabelType.PREF_LABEL)     continue;
    Collection<LabeledConcept> labeledResourcesOfUri=prefLabelsByResource.get(labeledConcept.getConcept());
    if (labeledResourcesOfUri == null) {
      labeledResourcesOfUri=new ArrayList<LabeledConcept>();
      prefLabelsByResource.put(labeledConcept.getConcept(),labeledResourcesOfUri);
    }
    labeledResourcesOfUri.add(labeledConcept);
  }
  return prefLabelsByResource;
}
Program: 38939
Project: 38939
Buggy source:
public InconsistentPrefLabels(ResourceLabelsCollector resourceLabelsCollector){
  super(resourceLabelsCollector,"String_Node_Str","String_Node_Str","String_Node_Str",IssueType.ANALYTICAL);
  this.resourceLabelsCollector=resourceLabelsCollector;
}

Fixed version (ground truth):
public InconsistentPrefLabels(ResourceLabelsCollector resourceLabelsCollector){
  super("String_Node_Str","String_Node_Str","String_Node_Str",IssueType.ANALYTICAL);
  this.resourceLabelsCollector=resourceLabelsCollector;
}
Program: 38940
Project: 38940
Buggy source:
public VocEvaluate(String[] args) throws OpenRDFException, IOException {
  parseCmdParams(args);
  if (outputVersion) {
    System.out.println("String_Node_Str" + getClass().getPackage().getImplementationVersion());
  }
  if (parsedCommand == null) {
    jc.usage();
  }
 else {
    listIssuesOrEvaluate();
  }
}

Fixed version (ground truth):
public VocEvaluate(String[] args) throws OpenRDFException, IOException {
  qskos=new QSkos();
  parseCmdParams(args);
  if (outputVersion) {
    System.out.println("String_Node_Str" + getClass().getPackage().getImplementationVersion());
  }
  if (parsedCommand == null) {
    jc.usage();
  }
 else {
    listIssuesOrEvaluate();
  }
}
Program: 38941
Project: 38941
Buggy source:
private void setup() throws OpenRDFException, IOException {
  setupLogging();
  RepositoryBuilder repositoryBuilder=new RepositoryBuilder();
  Repository repo=repositoryBuilder.setUpFromFile(new File(parsedCommand.vocabFilenames.get(0)),null,null);
  qskos=new QSkos();
  qskos.setRepositoryConnection(repo.getConnection());
  qskos.setAuthResourceIdentifier(parsedCommand.authoritativeResourceIdentifier);
  qskos.addSparqlEndPoint("String_Node_Str");
  qskos.addSparqlEndPoint("String_Node_Str");
  if (parsedCommand instanceof CommandAnalyze) {
    qskos.setSubsetSize(((CommandAnalyze)parsedCommand).randomSubsetSize_percent);
  }
  if (parsedCommand.enableSkosXl) {
    repositoryBuilder.enableSkosXlSupport();
  }
  if (!uriTrackingEnabled() && !parsedCommand.noProgressBar) {
    qskos.setProgressMonitor(new ConsoleProgressMonitor());
  }
}

Fixed version (ground truth):
private void setup() throws OpenRDFException, IOException {
  setupLogging();
  RepositoryBuilder repositoryBuilder=new RepositoryBuilder();
  Repository repo=repositoryBuilder.setUpFromFile(new File(parsedCommand.vocabFilenames.get(0)),null,null);
  qskos.setRepositoryConnection(repo.getConnection());
  qskos.setAuthResourceIdentifier(parsedCommand.authoritativeResourceIdentifier);
  qskos.addSparqlEndPoint("String_Node_Str");
  qskos.addSparqlEndPoint("String_Node_Str");
  if (parsedCommand instanceof CommandAnalyze) {
    qskos.setSubsetSize(((CommandAnalyze)parsedCommand).randomSubsetSize_percent);
  }
  if (parsedCommand.enableSkosXl) {
    repositoryBuilder.enableSkosXlSupport();
  }
  if (!uriTrackingEnabled() && !parsedCommand.noProgressBar) {
    qskos.setProgressMonitor(new ConsoleProgressMonitor());
  }
}
Program: 38942
Project: 38942
Buggy source:
/** 
 * Set an IProgressMonitor that is notified on changes in the evaluation progress for every managed issues.
 * @param progressMonitor monitor instance to be notified
 */
public void setProgressMonitor(IProgressMonitor progressMonitor){
  for (  Issue issue : registeredIssues) {
    issue.setProgressMonitor(progressMonitor);
  }
}

Fixed version (ground truth):
/** 
 * Set an IProgressMonitor that is notified on changes in the evaluation progress for every managed issues.
 * @param progressMonitor monitor instance to be notified
 */
public void setProgressMonitor(IProgressMonitor progressMonitor){
  this.progressMonitor=progressMonitor;
}
Program: 38943
Project: 38943
Buggy source:
public List<Issue> getAllIssues(){
  return registeredIssues;
}

Fixed version (ground truth):
public List<Issue> getAllIssues(){
  initialize();
  return registeredIssues;
}
Program: 38944
Project: 38944
Buggy source:
public void initialize(){
  registeredIssues.clear();
  addStatisticalIssues();
  try {
    addAnalyticalIssues();
    addSkosIntegrityIssues();
  }
 catch (  OpenRDFException e) {
    logger.error("String_Node_Str",e);
  }
}

Fixed version (ground truth):
private void initialize(){
  registeredIssues.clear();
  addStatisticalIssues();
  try {
    addAnalyticalIssues();
    addSkosIntegrityIssues();
  }
 catch (  OpenRDFException e) {
    logger.error("String_Node_Str",e);
  }
  for (  Issue issue : registeredIssues) {
    issue.setProgressMonitor(progressMonitor);
  }
}
Program: 38945
Project: 38945
Buggy source:
public Collection<Issue> getIssues(String commaSeparatedIssueIDs){
  if (commaSeparatedIssueIDs == null || commaSeparatedIssueIDs.isEmpty()) {
    return Collections.emptySet();
  }
  Collection<Issue> issues=new ArrayList<Issue>();
  StringTokenizer tokenizer=new StringTokenizer(commaSeparatedIssueIDs,"String_Node_Str");
  while (tokenizer.hasMoreElements()) {
    issues.add(findIssue(tokenizer.nextToken().trim()));
  }
  return issues;
}

Fixed version (ground truth):
public Collection<Issue> getIssues(String commaSeparatedIssueIDs){
  initialize();
  if (commaSeparatedIssueIDs == null || commaSeparatedIssueIDs.isEmpty()) {
    return Collections.emptySet();
  }
  Collection<Issue> issues=new ArrayList<Issue>();
  StringTokenizer tokenizer=new StringTokenizer(commaSeparatedIssueIDs,"String_Node_Str");
  while (tokenizer.hasMoreElements()) {
    issues.add(findIssue(tokenizer.nextToken().trim()));
  }
  return issues;
}
Program: 38946
Project: 38946
Buggy source:
private void setup() throws OpenRDFException, IOException {
  setupLogging();
  RepositoryBuilder repositoryBuilder=new RepositoryBuilder();
  Repository repo=repositoryBuilder.setUpFromFile(new File(parsedCommand.vocabFilenames.get(0)),null,null);
  qskos=new QSkos(repo.getConnection());
  qskos.setAuthResourceIdentifier(parsedCommand.authoritativeResourceIdentifier);
  qskos.addSparqlEndPoint("String_Node_Str");
  qskos.addSparqlEndPoint("String_Node_Str");
  if (parsedCommand instanceof CommandAnalyze) {
    qskos.setSubsetSize(((CommandAnalyze)parsedCommand).randomSubsetSize_percent);
  }
  if (parsedCommand.enableSkosXl) {
    repositoryBuilder.enableSkosXlSupport();
  }
  if (!uriTrackingEnabled() && !parsedCommand.noProgressBar) {
    qskos.setProgressMonitor(new ConsoleProgressMonitor());
  }
  qskos.initialize();
}

Fixed version (ground truth):
private void setup() throws OpenRDFException, IOException {
  setupLogging();
  RepositoryBuilder repositoryBuilder=new RepositoryBuilder();
  Repository repo=repositoryBuilder.setUpFromFile(new File(parsedCommand.vocabFilenames.get(0)),null,null);
  qskos=new QSkos(repo.getConnection());
  qskos.setAuthResourceIdentifier(parsedCommand.authoritativeResourceIdentifier);
  qskos.addSparqlEndPoint("String_Node_Str");
  qskos.addSparqlEndPoint("String_Node_Str");
  if (parsedCommand instanceof CommandAnalyze) {
    qskos.setSubsetSize(((CommandAnalyze)parsedCommand).randomSubsetSize_percent);
  }
  if (parsedCommand.enableSkosXl) {
    repositoryBuilder.enableSkosXlSupport();
  }
  if (!uriTrackingEnabled() && !parsedCommand.noProgressBar) {
    qskos.setProgressMonitor(new ConsoleProgressMonitor());
  }
}
Program: 38947
Project: 38947
Buggy source:
private Collection<URL> extractExternalResources(Collection<URL> allResources){
  Collection<URL> validExternalResources=new HashSet<URL>();
  for (  URL url : allResources) {
    if (isExternalResource(url) && isNonSkosURL(url)) {
      validExternalResources.add(url);
    }
  }
  return validExternalResources;
}

Fixed version (ground truth):
private Collection<URI> extractExternalResources(Collection<URI> allResources){
  Collection<URI> validExternalResources=new HashSet<URI>();
  for (  URI uri : allResources) {
    if (isExternalResource(uri) && isNonSkosURL(uri)) {
      validExternalResources.add(uri);
    }
  }
  return validExternalResources;
}
Program: 38948
Project: 38948
Buggy source:
private boolean isNonSkosURL(URL url){
  return !url.toString().contains(SparqlPrefix.SKOS.getNameSpace());
}

Fixed version (ground truth):
private boolean isNonSkosURL(URI url){
  return !url.toString().contains(SparqlPrefix.SKOS.getNameSpace());
}
Program: 38949
Project: 38949
Buggy source:
private boolean isExternalResource(URL url){
  String authResourceIdentifier=authoritativeConcepts.getAuthResourceIdentifier();
  if (authResourceIdentifier != null && !authResourceIdentifier.isEmpty()) {
    return !url.toString().toLowerCase().contains(authResourceIdentifier.toLowerCase());
  }
  throw new IllegalArgumentException("String_Node_Str");
}

Fixed version (ground truth):
private boolean isExternalResource(URI url){
  String authResourceIdentifier=authoritativeConcepts.getAuthResourceIdentifier();
  if (authResourceIdentifier != null && !authResourceIdentifier.isEmpty()) {
    return !url.toString().toLowerCase().contains(authResourceIdentifier.toLowerCase());
  }
  throw new IllegalArgumentException("String_Node_Str");
}
Program: 38950
Project: 38950
Buggy source:
@Override public Collection<Value> prepareData() throws OpenRDFException {
  extResourcesForConcept=new HashMap<Value,Collection<URL>>();
  findResourcesForConcepts(authoritativeConcepts.getPreparedData());
  return extractUnlinkedConcepts();
}

Fixed version (ground truth):
@Override public Collection<Value> prepareData() throws OpenRDFException {
  extResourcesForConcept=new HashMap<Value,Collection<URI>>();
  findResourcesForConcepts(authoritativeConcepts.getPreparedData());
  return extractUnlinkedConcepts();
}
Program: 38951
Project: 38951
Buggy source:
private void findResourcesForConcepts(Collection<Value> concepts){
  Iterator<Value> conceptIt=new MonitoredIterator<Value>(concepts,progressMonitor,"String_Node_Str");
  while (conceptIt.hasNext()) {
    Value concept=conceptIt.next();
    extResourcesForConcept.put(concept,findExternalResourcesForConcept(concept));
  }
}

Fixed version (ground truth):
private void findResourcesForConcepts(Collection<Value> concepts) throws RepositoryException {
  Iterator<Value> conceptIt=new MonitoredIterator<Value>(concepts,progressMonitor,"String_Node_Str");
  while (conceptIt.hasNext()) {
    Value concept=conceptIt.next();
    extResourcesForConcept.put(concept,extractExternalResources(getURIsOfConcept(concept)));
  }
}
Program: 38952
Project: 38952
Buggy source:
@Before public void setUp() throws IOException, OpenRDFException {
  qskos=new QSkos(new RepositoryBuilder().setUpFromTestResource("String_Node_Str").getConnection());
  qskos.initialize();
}

Fixed version (ground truth):
@Before public void setUp() throws IOException, OpenRDFException {
  qskos=new QSkos(new RepositoryBuilder().setUpFromTestResource("String_Node_Str").getConnection());
}
Program: 38953
Project: 38953
Buggy source:
private void addAllIssues() throws OpenRDFException {
  issuesToTest.clear();
  HierarchyGraphBuilder hierarchyGraphBuilder=new HierarchyGraphBuilder(vocabRepository);
  ResourceLabelsCollector resourceLabelsCollector=new ResourceLabelsCollector(vocabRepository);
  InvolvedConcepts involvedConcepts=new InvolvedConcepts(vocabRepository);
  AuthoritativeConcepts authoritativeConcepts=new AuthoritativeConcepts(involvedConcepts);
  authoritativeConcepts.setBaseURI(baseURI);
  authoritativeConcepts.setAuthResourceIdentifier(authResourceIdentifier);
  HttpURIs httpURIs=new HttpURIs(vocabRepository);
  issuesToTest.add(involvedConcepts);
  issuesToTest.add(authoritativeConcepts);
  issuesToTest.add(new OrphanConcepts(involvedConcepts));
  issuesToTest.add(new MissingOutLinks(authoritativeConcepts));
  issuesToTest.add(new LexicalRelations(involvedConcepts));
  issuesToTest.add(new SemanticRelations(vocabRepository));
  issuesToTest.add(new AggregationRelations(vocabRepository));
  ConceptSchemes conceptSchemes=new ConceptSchemes(vocabRepository);
  issuesToTest.add(conceptSchemes);
  issuesToTest.add(new at.ac.univie.mminf.qskos4j.issues.count.Collections(vocabRepository));
  issuesToTest.add(httpURIs);
  issuesToTest.add(new DisconnectedConceptClusters(involvedConcepts));
  issuesToTest.add(new MissingOutLinks(authoritativeConcepts));
  issuesToTest.add(new HierarchicalCycles(hierarchyGraphBuilder));
  issuesToTest.add(new NonHttpResources(vocabRepository));
  issuesToTest.add(new OmittedOrInvalidLanguageTags(vocabRepository));
  issuesToTest.add(new IncompleteLanguageCoverage(involvedConcepts));
  issuesToTest.add(new InconsistentPrefLabels(resourceLabelsCollector));
  issuesToTest.add(new DisjointLabelsViolations(resourceLabelsCollector));
  issuesToTest.add(new OverlappingLabels(involvedConcepts));
  issuesToTest.add(new ValuelessAssociativeRelations(vocabRepository));
  issuesToTest.add(new UndefinedSkosResources(vocabRepository));
  issuesToTest.add(new UndocumentedConcepts(authoritativeConcepts));
  issuesToTest.add(new SolelyTransitivelyRelatedConcepts(vocabRepository));
  issuesToTest.add(new OmittedTopConcepts(conceptSchemes));
  issuesToTest.add(new TopConceptsHavingBroaderConcepts(vocabRepository));
  issuesToTest.add(new MappingClashes(vocabRepository));
  issuesToTest.add(new RelationClashes(hierarchyGraphBuilder));
  BrokenLinks brokenLinks=new BrokenLinks(httpURIs);
  brokenLinks.setSubsetSize(randomSubsetSize_percent);
  brokenLinks.setExtAccessDelayMillis(extAccessDelayMillis);
  issuesToTest.add(brokenLinks);
  MissingInLinks missingInLinks=new MissingInLinks(authoritativeConcepts);
  missingInLinks.setQueryDelayMillis(extAccessDelayMillis);
  missingInLinks.setSubsetSize(randomSubsetSize_percent);
  for (  String sparqlEndpointUrl : sparqlEndpointUrls) {
    missingInLinks.addSparqlEndPoint(sparqlEndpointUrl);
  }
  issuesToTest.add(missingInLinks);
}

Fixed version (ground truth):
private void addAllIssues() throws OpenRDFException {
  issuesToTest.clear();
  addStatisticalIssues();
  addAnalyticalIssues();
  addSkosIntegrityIssues();
}
Program: 38954
Project: 38954
Buggy source:
@Test public void testResourcesNonHttpUriCount() throws OpenRDFException {
  Assert.assertEquals(4,nonHttpResourcesForResources.getResult().getData().size());
}

Fixed version (ground truth):
@Test public void testResourcesNonHttpUriCount() throws OpenRDFException {
  Assert.assertEquals(4,httpResourcesForUriSchemeViolations.getResult().getData().size());
}
Program: 38955
Project: 38955
Buggy source:
@Test public void testConceptsNonHttpUriCount() throws OpenRDFException {
  Assert.assertEquals(1,nonHttpResourcesForConcepts.getResult().getData().size());
}

Fixed version (ground truth):
@Test public void testConceptsNonHttpUriCount() throws OpenRDFException {
  Assert.assertEquals(1,httpUriSchemeViolationsForConcepts.getResult().getData().size());
}
Program: 38956
Project: 38956
Buggy source:
@Before public void setUp() throws OpenRDFException, IOException {
  nonHttpResourcesForConcepts=new NonHttpResources(setUpRepository("String_Node_Str"));
  nonHttpResourcesForResources=new NonHttpResources(setUpRepository("String_Node_Str"));
}

Fixed version (ground truth):
@Before public void setUp() throws OpenRDFException, IOException {
  httpUriSchemeViolationsForConcepts=new HttpUriSchemeViolations(setUpRepository("String_Node_Str"));
  httpResourcesForUriSchemeViolations=new HttpUriSchemeViolations(setUpRepository("String_Node_Str"));
}