@Test(
      groups = "wso2.greg",
      description = "Create new life cycle",
      dependsOnMethods = "testCreateService")
  public void testCreateNewLifeCycle()
      throws LifeCycleManagementServiceExceptionException, IOException, InterruptedException {

    String resourcePath =
        getTestArtifactLocation()
            + "artifacts"
            + File.separator
            + "GREG"
            + File.separator
            + "lifecycle"
            + File.separator
            + "MultiplePromoteDemoteLC.xml";
    String lifeCycleContent = FileManager.readFile(resourcePath);
    lifeCycleManagementClient.addLifeCycle(lifeCycleContent);
    String[] lifeCycles = lifeCycleManagementClient.getLifecycleList();
    boolean lcStatus = false;
    for (String lc : lifeCycles) {
      if (lc.equalsIgnoreCase(LC_NAME)) {
        lcStatus = true;
      }
    }
    assertTrue(lcStatus, "LifeCycle not found");
  }
 private void deployEventReceivers() throws IOException {
   String streamResourceDir =
       FrameworkPathUtil.getSystemResourceLocation() + "webservice" + File.separator;
   String streamsLocation =
       FrameworkPathUtil.getCarbonHome()
           + File.separator
           + "repository"
           + File.separator
           + "deployment"
           + File.separator
           + "server"
           + File.separator
           + "eventreceivers"
           + File.separator;
   FileManager.copyResourceToFileSystem(
       streamResourceDir + "webservice_test_table1.xml",
       streamsLocation,
       "webservice_test_table1.xml");
 }
 // invalid wsdl form file system
 @Test(
     groups = "wso2.greg",
     description = "invalid wsdl form file system using admin services",
     expectedExceptions = OMException.class,
     dependsOnMethods = "testInvalidAdditionWSDL")
 public void testAddInvalidWsdlFromFileSystem() throws RegistryException, IOException {
   // clarity automation api for registry
   String resourcePath =
       getTestArtifactLocation()
           + "artifacts"
           + File.separator
           + "GREG"
           + File.separator
           + "wsdl"
           + File.separator
           + "AutomatedInvalidWSDL.wsdl"; // the
   // path
   WsdlManager wsdlManager2 = new WsdlManager(governanceRegistry);
   Wsdl wsdl2 = wsdlManager2.newWsdl(FileManager.readFile(resourcePath).getBytes());
   wsdlManager2.addWsdl(wsdl2);
 }