Class TestManagerService

java.lang.Object
com.ads.services.webservice.TestManagerService

public class TestManagerService extends Object
Contains the methods which performs the operations like Creation, Update, Deletion and Retrieval of TestCase, TestCases, ValidationStep, and ValidationSteps. *
All the WebServices methods have return type String - meaning if the method is execution is successful, then it will return a string in the form of JSON or XML String based on the outputFormat parameter given by the user.
  • Constructor Details

    • TestManagerService

      public TestManagerService()
  • Method Details

    • addTestCaseByNodeId

      public String addTestCaseByNodeId(String userName, String password, String outputFormat, int nodeId, String nodeType, String testCaseObjJson)
      TestCase will be added for the specified nodeId of nodeType with the details given in TestCase Object.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId or mapId or tableId.
      Specifying the nodeType, nodeId and testCaseName in TestCase Object are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseObjJson - String - TestCase Object.
      Returns:
      String - If TestCase is added successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'testCaseObjJson' JSON :
      {
      "testCaseTypeId": "",
      "priorityName": null,
      "lastModifiedDateTime": "",
      "attachFile": null,
      "approvedBy": "",
      "docMode": "",
      "subjectId": "",
      "saveFilePath": "",
      "priorityId": "",
      "testDocApprovalDate": "",
      "testDocObject": "",
      "approved": "false",
      "validationStepMap": {},
      "documentLink": "",
      "testCaseLevel": "",
      "approvalFlag": "",
      "testDocId": "",
      "validExcelCase": false,
      "testDocType": "",
      "expectedResult": "",
      "testcaseLabel": "",
      "modifiedDate": "",
      "mapId": "",
      "extendable": "false",
      "projectName": "",
      "projectId": "",
      "testCaseId": "",
      "actualResult": "",
      "attachDoc": "",
      "description": "",
      "testCaseComments": "",
      "validationStepsList": [],
      "testSQLScript": "",
      "testDocOwner": "",
      "testStepComments": "",
      "testTypeName": null,
      "statusName": null,
      "modifiedBy": "",
      "documentStatus": "",
      "testCaseName": "",
      "mapName": "",
      "excelInvalidRows": null,
      "objectId": "",
      "subjectName": "",
      "testDocIntededUseDescr": "",
      "isCopied": false,
      "testCaseLabel": "",
      "externalTestcaseId": null,
      "message": "",
      "objectName": "",
      "testDocName": "",
      "successOption": ""
      }

      Since:
      7.0
    • addValidationStep

      public String addValidationStep(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName, String validationStepObjJson)
      ValidationStep will be added for the specified testCaseName of nodeId, nodeType with details given in TestCaseValidationStep Object.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId or mapId or tableId.
      Specifying testCaseName, nodeId, nodeType and validationStepName are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String
      validationStepObjJson - ValidationStep Object
      Returns:
      String - If ValidationStep is added successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepObjJson' JSON :
      {
      "stepName": "",
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }

      Since:
      7.0
    • addValidationSteps

      public String addValidationSteps(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName, String validationStepsJsonArray)
      ValidationSteps will be added for the specified testCaseName of nodeId, nodeType with details given in the List of TestCaseValidationStep Objects.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId or mapId or tableId.
      Specifying testCaseName, nodeId, nodeType and validationStepNames are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String
      validationStepsJsonArray - String - List of validationSteps
      Returns:
      String - If ValidationSteps are added successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepsJsonArray' for this:
      [
      {
      "stepName": "",
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      },
      {
      "stepName": "",
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }
      ]

      Since:
      7.0
    • addValidationStepByTestCaseId

      public String addValidationStepByTestCaseId(String userName, String password, String outputFormat, int testCaseId, String validationStepObjJson)
      ValidationStep will be added for the specified testCaseId with details given in TestCaseValidationStep Object. Specifying testCaseId, validationStepName are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String
      testCaseId - int
      validationStepObjJson - String - ValidationStep Object
      Returns:
      String - If ValidationStep is added successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepObjJson' JSON :
      {
      "stepName": "",
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }

      Since:
      7.0
    • addValidationStepsByTestCaseId

      public String addValidationStepsByTestCaseId(String userName, String password, String outputFormat, int testCaseId, String validationStepsJsonArray)
      ValidationSteps will be added for the specified testCaseId with details given in the List of TestCaseValidationStep Objects.
      Specifying testCaseId and validationStepName's are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      validationStepsJsonArray - String - List of ValidationSteps
      Returns:
      String - If ValidationSteps are added successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepsJsonArray' for this:
      [
      {
      "stepName": "",
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      },
      {
      "stepName": "",
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }
      ]

      Since:
      7.0
    • updateTestCase

      public String updateTestCase(String userName, String password, String outputFormat, String testCaseObjJson)
      TestCase will be updated with the details specified in TestCase Object. Specifying testCaseId and testCaseName are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseObjJson - String - TestCase Object
      Returns:
      String - If TestCase is updated successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'testCaseObjJson' for this:
      {
      "testCaseName": "Test case updated",
      "testCaseId" : 0,
      "testcaseLabel": "",
      "testCaseTypeId": "",
      "actualResult": "",
      "attachDoc": "",
      "description": "",
      "testCaseLevel": "",
      "testCaseComments": "",
      "expectedResult": ""
      }

      Since:
      7.0
    • updateValidationStep

      public String updateValidationStep(String userName, String password, String outputFormat, String validationStepObjJson)
      ValidationStep will be updated as the specified TestCaseValidationStep Object.
      Specifying validationStepId is mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      validationStepObjJson - String - ValidationStep Object
      Returns:
      String - If ValidationStep is updated successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepObjJson' for this:
      {
      "stepName": "",
      "validationStepId": ,
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }

      Since:
      7.0
    • updateValidationSteps

      public String updateValidationSteps(String userName, String password, String outputFormat, String validationStepJsonArray)
      ValidationSteps will be updated as the specified TestCaseValidationStep Objects.
      Specifying validationStepIds are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      validationStepJsonArray - String - List of ValidationStep
      Returns:
      String - If ValidationSteps are updated successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepJsonArray' JSON :
      [
      {
      "stepName": "",
      "validationStepId": 0,
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      },
      {
      "stepName": "",
      "validationStepId": 0,
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }
      ]

      Since:
      7.0
    • updateValidationStepsByTestCaseId

      public String updateValidationStepsByTestCaseId(String userName, String password, String outputFormat, int testCaseId, String validationStepsJsonArray)
      ValidationSteps will be updated of the specified testCaseId, with the details specified in TestCaseValidationStep Objects.
      Specifying the testCaseId and validationStepNames are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      validationStepsJsonArray - String - List Of validationSteps
      Returns:
      String - If ValidationSteps are updated successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Sample 'validationStepsJsonArray' for this:
      [
      {
      "stepName": "",
      "validationStepId": 0,
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      },
      {
      "stepName": "",
      "validationStepId": 0,
      "comments": "",
      "validationStepType": "",
      "description": "",
      "expectedResult": "",
      "actualResult": ""
      }
      ]

      Since:
      7.0
    • getTestCase

      public String getTestCase(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName)
      Returns the TestCase Details such as TestCaseId, TestCaseName, TestCaseLabel, TypeOfTesting, Description and AuditHistory etc... for the specified testCaseName present in the nodeId of nodeType.
      Specifying the testCaseName, nodeId, nodeType are mandatory.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId, mapId or tableId.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String
      Returns:
      String - If TestCase is returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • getTestCases

      public String getTestCases(String userName, String password, String outputFormat, String nodeType, int nodeId)
      Returns the List of TestCase objects with Details such as TestCaseId, TestCaseName, TestCaseLabel, TypeOfTesting, Description and AuditHistory etc...for the specified nodeId of nodeType.
      Specifying the nodeId, nodeType are mandatory.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId, mapId or tableId.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      Returns:
      String - If TestCases are returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • getTestCaseByTestCaseId

      public String getTestCaseByTestCaseId(String userName, String password, String outputFormat, int testCaseId)
      Returns the TestCase Details such as TestCaseId, TestCaseName, TestCaseLabel, TypeOfTesting, Description and AuditHistory etc... for the specified testCaseId.
      Specifying the testCaseId is mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      Returns:
      String - If TestCase is returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • getValidationStep

      public String getValidationStep(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName, String validationStepName)
      Parameters:
      userName - String
      password - String
      outputFormat - String
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String - Valid values: JSON or XML
      validationStepName - String
      Returns:
      String - If ValidationStep is returned successfully, it will return success message otherwise failure message.
    • getValidationSteps

      public String getValidationSteps(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName)
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String
      Returns:
      String - If ValidationSteps are returned successfully, it will return success message otherwise failure message.
    • getValidationStepByTestCaseId

      public String getValidationStepByTestCaseId(String userName, String password, String outputFormat, int testCaseId, String validationStepName)
      Returns the TestCaseValidationStep object with Details such as StepName, StepType, Description, ExpectedResult, ActualResult, StepComments and AuditHistory etc...of the specified testCaseId, validationStepName.
      Specifying the testCaseId, validationStepName are mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      validationStepName - String
      Returns:
      String - If ValidationStep is returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • getValidationStepsByTestCaseId

      public String getValidationStepsByTestCaseId(String userName, String password, String outputFormat, int testCaseId)
      Returns the TestCaseValidationStep objects with Details such as StepName, StepType, Description, ExpectedResult, ActualResult, StepComments and AuditHistory etc...of the specified testCaseId.
      Specifying the testCaseId is mandatory.
      outputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      Returns:
      String - If ValidationSteps are returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • getTestCasesByIds

      public String getTestCasesByIds(String userName, String password, String outputFormat, String testCaseIdsJson)
      Returns the TestCases with Details such as TestCaseId, TestCaseName, TestCaseLabel, TypeOfTesting, Description and AuditHistory etc... for the specified testCaseId's.
      Specifying the testCaseId's are mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseIdsJson - String - List of TestCaseIds
      Returns:
      String - If TestCases are returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • getValidationStepById

      public String getValidationStepById(String userName, String password, String outputFormat, int validationStepId)
      Returns the TestCaseValidationStep object with Details such as StepName, StepType, Description, ExpectedResult, ActualResult, StepComments and AuditHistory etc...of the specified validationStepId.
      Specifying the validationStepId is mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      validationStepId - String
      Returns:
      String - If ValidationStep is returned successfully, it will return success message otherwise failure message.
      Since:
      7.0
    • deleteTestCase

      public String deleteTestCase(String userName, String password, String outputFormat, int testCaseId)
      Removes the TestCase of the specified testCaseId. All the details related to that particular testCase are deleted.
      Specifying the testCaseId is mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      Returns:
      String - If TestCase is deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteTestCases

      public String deleteTestCases(String userName, String password, String outputFormat, String testCaseIdsJsonArray)
      Removes the TestCases of the specified List of testCaseId's. All the details related to those particular testCases are deleted.
      Specifying the List of testCaseId's are mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseIdsJsonArray - String - List of testCasesIds
      Returns:
      String - If TestCases are deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteValidationStep

      public String deleteValidationStep(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName, String stepName)
      Removes the ValidationStep of the specified stepName, testCaseName, nodeId, nodeType. All the details related to those particular stepName are deleted.
      Specifying the testCaseName, stepName, nodeId and nodeType are mandatory.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId, subjectId or environmentId.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String
      stepName - String
      Returns:
      String - If ValidationStep is deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteValidationSteps

      public String deleteValidationSteps(String userName, String password, String outputFormat, String nodeType, int nodeId, String testCaseName, String stepNamesJsonArray)
      Removes the ValidationSteps of the specified List of stepNames, testCaseName, nodeId, nodeType. All the details related to those particular stepNames are deleted.
      Specifying the testCaseName, stepNames, nodeId and nodeType are mandatory.
      nodeType can be either MM_PROJECT, MM_MAPPING, SM_TABLE. Depending upon the nodeType, nodeId will be either projectId, subjectId or environmentId.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      nodeType - String - Node Object - valid Types - MM_PROJECT, MM_MAPPING, SM_TABLE.
      nodeId - int
      testCaseName - String
      stepNamesJsonArray - String - List of stepNames
      Returns:
      String - If ValidationSteps are deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteValidationStepsByTestCaseId

      public String deleteValidationStepsByTestCaseId(String userName, String password, String outputFormat, int testCaseId)
      Removes the ValidationSteps of the specified testCaseId. All the details related to the particular testCaseId are deleted.
      Specifying the testCaseId is mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      Returns:
      String - If ValidationSteps are deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteValidationStepByTestCaseId

      public String deleteValidationStepByTestCaseId(String userName, String password, String outputFormat, int testCaseId, String stepName)
      Removes the ValidationStep of the specified testCaseId and stepName. All the details related to the particular testCaseId are deleted.
      Specifying the testCaseId and stepName are mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      stepName - String
      Returns:
      String - If ValidationStep is deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteValidationStepsByListOfStepNames

      public String deleteValidationStepsByListOfStepNames(String userName, String password, String outputFormat, int testCaseId, String stepNamesJsonArray)
      Removes the ValidationSteps of the specified testCaseId and List of stepNames. All the details related to the particular testCaseId are deleted.
      Specifying the testCaseId and List of stepNames are mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      testCaseId - int
      stepNamesJsonArray - String - List of StepNames
      Returns:
      String - If ValidationSteps are deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.

      Example for this:
      ["step1","step2","step3"]

      Since:
      7.0
    • deleteValidationStepsByIds

      public String deleteValidationStepsByIds(String userName, String password, String outputFormat, String stepIdsJsonArray)
      Removes the TestSteps of the specified List of stepIds. All the details related to those stepIds are deleted.
      Specifying the List of stepIds are mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      stepIdsJsonArray - String - List of stepIds
      Returns:
      String - If TestSteps are deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0
    • deleteValidationStepById

      public String deleteValidationStepById(String userName, String password, String outputFormat, int validationStepId)
      Removes the ValidationStep of the specified validationStepId. All the details related to the particular validationStepId are deleted.
      Specifying the validationStepId is mandatory.
      Parameters:
      userName - String
      password - String
      outputFormat - String - Valid values: JSON or XML
      validationStepId - String
      Returns:
      String - If ValidationStep is deleted successfully, it will return RequestStatus Object consisting of Request success flag, status message and userObject etc... in the form of JSON or XML String.
      Since:
      7.0