Program: 114922
Project: 114922
Buggy source:
@Test(groups={"String_Node_Str"},description="String_Node_Str",priority=1) public void testCreateApiWithDifferentProductionEndpoints() throws Exception {
  String tags="String_Node_Str";
  String description="String_Node_Str";
  firstProductionEndPoint=gatewayUrlsWrk.getWebAppURLHttp() + webApp1;
  secondProductionEndPoint=gatewayUrlsWrk.getWebAppURLHttp() + webApp2;
  thirdProductionEndPoint=gatewayUrlsWrk.getWebAppURLHttp() + webApp3;
  ArrayList<String> endpointLB=new ArrayList<String>();
  endpointLB.add(firstProductionEndPoint);
  endpointLB.add(secondProductionEndPoint);
  endpointLB.add(thirdProductionEndPoint);
  providerName=publisherContext.getContextTenant().getContextUser().getUserName();
  APICreationRequestBean apiCreateRequestBean=new APICreationRequestBean(apiName,context,version,providerName,endpointLB);
  apiCreateRequestBean.setTier(tier);
  apiCreateRequestBean.setResourceBeanList(resourceBeanList);
  apiCreateRequestBean.setVisibility(visibility);
  apiCreateRequestBean.setTags(tags);
  apiCreateRequestBean.setDescription(description);
  apiCreateRequestBean.setEndpointType(endPointType);
  HttpResponse apiCreateResponse=apiPublisher.addAPI(apiCreateRequestBean);
  assertEquals(apiCreateResponse.getResponseCode(),Response.Status.OK.getStatusCode(),"String_Node_Str");
  JSONObject jsonObject=new JSONObject(apiCreateResponse.getData());
  assertFalse(jsonObject.getBoolean("String_Node_Str"),"String_Node_Str");
  HttpResponse verifyApi=apiPublisher.getApi(apiName,providerName,version);
  JSONObject verifyApiJsonObject=new JSONObject(verifyApi.getData());
  assertFalse(verifyApiJsonObject.getBoolean("String_Node_Str"),"String_Node_Str");
  APILifeCycleStateRequest updateRequest=new APILifeCycleStateRequest(apiName,providerName,APILifeCycleState.PUBLISHED);
  HttpResponse statusUpdateResponse=apiPublisher.changeAPILifeCycleStatus(updateRequest);
  assertEquals(statusUpdateResponse.getResponseCode(),Response.Status.OK.getStatusCode(),"String_Node_Str");
  JSONObject statusUpdateJsonObject=new JSONObject(statusUpdateResponse.getData());
  assertFalse(statusUpdateJsonObject.getBoolean("String_Node_Str"),"String_Node_Str");
}

Fixed version (ground truth):
@Test(groups={"String_Node_Str"},description="String_Node_Str",priority=1) public void testCreateApiWithDifferentProductionEndpoints() throws Exception {
  String tags="String_Node_Str";
  String description="String_Node_Str";
  firstProductionEndPoint=gatewayUrlsWrk.getWebAppURLHttp() + webApp1;
  secondProductionEndPoint=gatewayUrlsWrk.getWebAppURLHttp() + webApp2;
  thirdProductionEndPoint=gatewayUrlsWrk.getWebAppURLHttp() + webApp3;
  ArrayList<String> endpointLB=new ArrayList<String>();
  endpointLB.add(firstProductionEndPoint);
  endpointLB.add(secondProductionEndPoint);
  endpointLB.add(thirdProductionEndPoint);
  providerName=publisherContext.getContextTenant().getContextUser().getUserName();
  APICreationRequestBean apiCreateRequestBean=new APICreationRequestBean(apiName,context,version,providerName,endpointLB);
  apiCreateRequestBean.setTiersCollection(tier);
  apiCreateRequestBean.setResourceBeanList(resourceBeanList);
  apiCreateRequestBean.setVisibility(visibility);
  apiCreateRequestBean.setTags(tags);
  apiCreateRequestBean.setDescription(description);
  apiCreateRequestBean.setEndpointType(endPointType);
  HttpResponse apiCreateResponse=apiPublisher.addAPI(apiCreateRequestBean);
  assertEquals(apiCreateResponse.getResponseCode(),Response.Status.OK.getStatusCode(),"String_Node_Str");
  JSONObject jsonObject=new JSONObject(apiCreateResponse.getData());
  assertFalse(jsonObject.getBoolean("String_Node_Str"),"String_Node_Str");
  HttpResponse verifyApi=apiPublisher.getApi(apiName,providerName,version);
  JSONObject verifyApiJsonObject=new JSONObject(verifyApi.getData());
  assertFalse(verifyApiJsonObject.getBoolean("String_Node_Str"),"String_Node_Str");
  APILifeCycleStateRequest updateRequest=new APILifeCycleStateRequest(apiName,providerName,APILifeCycleState.PUBLISHED);
  HttpResponse statusUpdateResponse=apiPublisher.changeAPILifeCycleStatus(updateRequest);
  assertEquals(statusUpdateResponse.getResponseCode(),Response.Status.OK.getStatusCode(),"String_Node_Str");
  JSONObject statusUpdateJsonObject=new JSONObject(statusUpdateResponse.getData());
  assertFalse(statusUpdateJsonObject.getBoolean("String_Node_Str"),"String_Node_Str");
}