Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

In the previous versions of Qualitia (below 8.0.0), at many places there were some public static variables and methods used with the intention of making it accessible throughout the code. These variables/methods were generally used in classes such as callController, Controller, QualitiaOffline , GLOBALS, QualitiaSelenium ,QualitiaTestCase ,FwUtil ,QualitiaMobile. They had various usages. 

In the latest Qualitia 8.0.0 version, these public api’s are the alternatives for the public static variables/methods used in older Qualitia Versions. 

Example :- 

Older Qualitia Versions (public static variables) 

 Latest Qualitia Version Public API 

1.) FwUtil.storeData() 

2.) Controller.STOREHASHMAP 

3.) Controller.testCaseName 

4.) Controller.suiteName 

5.) Controller.strObjectID 

6.) QualitiaTestCase.isCustomAction 

7.) QualitiaSelenium.getDriver() 

8.) GLOBALS.CONFIG_OPTIMIZATION_MODE 

9.) GLOBALS.mobileUDID 

10.) FwUtil.resolveObjectProperties() 

1.) storeData(String key , String Value) 

2.) getStoredData(String key)  

3.) getTestCaseName() 

4.) getSuiteName() 

5.) getObjectID 

6.) isCustomAction 

7.) getWebDriver 

8.) isOptimizationModeEnabled 

9.) getMobileUDID 

10.) resolveObjectProperties 

 

 

  1. getWebDriver() 

=     This method is used to get the webdriver being used. 

    this is an alternative to QualitiaSelenium.getDriver() 

  

    For example, If the user wants to find an element on browser using ID, user can do it as: 

     

    In earlier versions: 

                element = QualitiaSelenium.getDriver().findElement(By.id(locator)); 

            } 

     

    In Qualitia 8.0.0: 

                element = getWebDriver().findElement(By.id(locator)); 

            } 

 

  1. getMobileDriver() 

=     This method is used to get the mobile driver being used. 

    this is an alternative to QualitiaMobile.getDriver() 

  

    For example, If the user wants to find an element on browser using ID, user can do it as: 

     

    In earlier versions: 

  • if (locatorType.equalsIgnoreCase(CONSTANTS.XPATH)) { 

                element = QualitiaMobile.getDriver().findElementByXPath(By.id(locator)); 

            } 

     

    In Qualitia 8.0.0: 

  • if (locatorType.equalsIgnoreCase(CONSTANTS.XPATH)) { 

                element = getMobileDriver().findElementByXPath(By.id(locator)); 

 

3.) storeData(String key, String value) 

= this method is used to store environment data in StoreHashMap. 

This is an alternative to FwUtil.storeData(). 

 

4.)  getStoredData(String key) 

= This method is used to get the value of particular key stored in StoreHashMap. 

This is an alternative to Controller.STOREHASHMAP.get() 

 

  1. storeDataContainsValue(String value) 

= This method is used to find if Storehashmap has the particular value present or not.  

  

If it returns true then the Storehashmap has value else value is not present as store data.  

  

This is an alternative to Controller.STOREHASHMAP.containsValue() 

 

  1. removeFromStoreData(String key) 

= This method is used to remove store data with particular key from StoreHashMap. 

This is an alternative to Controller.STOREHASHMAP.remove() 

 

  1. getStoredDataAsObject 

= this method is used to get stored data as Objects. 

  

8)storeDataAsObject(String key, Object value) 

=7 this method is used to store environment data  as objects in StoreHashMap. 

T7his is an alternative to FwUtil.storeData(). 

  

9)storeData(Map<String, String> storeMap) 

= this method is used to store environment data in StoreHashMap where all the data is stored in storeMap along with their keys. 

This is an alternative to FwUtil.storeData(). 

  

10)storeDataAsObject(Map<String, Object> storeMap) 

= this method is used to store environment data  as objects in StoreHashMap where all the object data is stored in storeMap along with their keys. 

 

11) storeDataContainsKey(String key) 

= This method is used to find if Storehashmap has the particular key present of not. 

If it returns true then the Storehashmap has key else key is not present as store data. 

This is an alternative to Controller.STOREHASHMAP.containsKey() 

 

 

 

12) setCurrentWebExecutionPlatform(value)  

=     This method is used to set the value of "CurrentWebExecutionPlatform".  

    Value can either be "DESKTOP" or "MOBILE" which can be set using "WebExecutionPlatform.DESKTOP" and "WebExecutionPlatform.MOBILE" respectively.  

    This can be used when the testcase switches platforms while execution.  

    This is an alternative to  QualitiaTestCase.setCurrentWebExecutionPlatform(). 

     

    For example: If user wants the current action to execute on Desktop, he can set it as: 

     

     In earlier versions: 

  • QualitiaTestCase.setCurrentWebExecutionPlatform(WebExecutionPlatform.DESKTOP); 

     

     In Qualitia 8.0.0: 

  • setCurrentWebExecutionPlatform(WebExecutionPlatform.DESKTOP) 

     

     

13) getCurrentWebExecutionPlatform() 

=      This method is used to get the value of "CurrentWebExecutionPlatform".  

    Value can either be "WebExecutionPlatform.DESKTOP" or "WebExecutionPlatform.MOBILE".  

    This can be used to know which platform is the testcase running on currently. 

    This is an alternative to  QualitiaTestCase.getCurrentWebExecutionPlatform() 

     

    For example: If user wants to do a particular operation when testcase is running on Desktop and another operation when testcase is running on Mobile, he can do it as: 

     

     In earlier versions: 

  • if(QualitiaTestCase.getCurrentWebExecutionPlatform().equals(WebExecutionPlatform.DESKTOP) 

        { 

        //Desktop related operation 

        } 

        else if(QualitiaTestCase.getCurrentWebExecutionPlatform().equals(WebExecutionPlatform.MOBILE) 

        { 

        //Mobile related operation 

        } 

     

     In Qualitia 8.0.0: 

        if(getCurrentWebExecutionPlatform().equals(WebExecutionPlatform.DESKTOP) 

        { 

        //Desktop related operation 

        } 

        else if(getCurrentWebExecutionPlatform().equals(WebExecutionPlatform.MOBILE) 

        { 

        //Mobile related operation 

        } 

 

  1. isCurrentWebExecutionPlatformMobile()  

  

This method is used to know if the current platform that the testcase is executing on is     MOBILE or not. It returns true if the current web execution platform is Mobile and returns false if it is Desktop.  

  

This is an alternative to CommonUtil.isCurrentWebExecutionPlatformMobile().  

  

For example: If user wants to do a particular operation when testcase is running on Mobile, he can do it as:  

  

     In earlier versions:  

  

        if(CommonUtil.isCurrentWebExecutionPlatformMobile())  

  

        {  

  

        //Mobile related operation  

  

        }  

  

  

  

     In Qualitia 8.0.0:  

  

        if(isCurrentWebExecutionPlatformMobile())  

  

        {  

  

        //Mobile related operation  

  

        }  

     

  1. getIeDriverPath() 

=     This method is used to get the value of Internet explorer driver path which is provided in execution profile.  

    The value can be either given by user in the execution profile or if driver is downloaded automatically then it is a default value. 

    This is an alternative to GLOBALS.CONFIG_IE_DRIVERPATH. 

     

   For example, if the user wants to set system property value for IE driver, he can do it as: 

     

    In earlier versions: 

        System.setProperty("webdriver.ie.driver", GLOBALS.CONFIG_IE_DRIVERPATH); 

    In Qualitia 8.0.0: 

        System.setProperty("webdriver.ie.driver", GLOBALS.CONFIG_IE_DRIVERPATH); 

     

  1. getChromeDriverPath() 

=     This method is used to get the value of Google Chrome driver path which is provided in execution profile.  

    The value can be either given by user in the execution pofile or if driver is downloaded automatically then it is a default value. 

    This is an alternative to GLOBALS.CONFIG_CHROME_DRIVERPATH. 

     

    For example, if the user wants to set system property value for IE driver, he can do it as: 

     

    In earlier versions: 

        System.setProperty("webdriver.chrome.driver", GLOBALS.CONFIG_CHROME_DRIVERPATH); 

    In Qualitia 8.0.0: 

        System.setProperty("webdriver.chrome.driver", GLOBALS.CONFIG_CHROME_DRIVERPATH); 

     

  1. getFirefoxDriverPath() 

=     This method is used to get the value of Firefox driver path i.e. geckodriver which is provided in execution profile.  

    The value can be either given by user in the execution profile or if driver is downloaded automatically then it is a default value. 

    This is an alternative to GLOBALS.CONFIG_FF_DRIVERPATH. 

     

    For example, if the user wants to set system property value for IE driver, he can do it as: 

     

    In earlier versions: 

        System.setProperty("webdriver.gecko.driver", GLOBALS.CONFIG_FF_DRIVERPATH); 

    In Qualitia 8.0.0: 

        System.setProperty("webdriver.gecko.driver", GLOBALS.CONFIG_FF_DRIVERPATH); 

     

 

10) getActionResponse() 

=     In previous versions of qualitia, all the action methods used to return int value. In latest engine, the return value of all the actions is ActionResponse. 

    It has two parameters: Message and ExecutionResult. 

    Message is the statement which you can provided with different outcomes of actions. 

    ExecutionResult is the output of the action which can be PASSED, FAILED, DEFECT or NOT_EXECUTED. 

     

    For example, if a user wants to write a custom action for checking two strings are equal, he can do it as: 

     

    In earlier versions: 

     

    public int EqualStrings(String a, String b) 

    { 

    if(a.equals(b)) 

    { 

    DataLogger.writeToDebugAndInfoLogs("they are equal"); 

    return 0; 

    } 

    else 

    { 

    DataLogger.writeToDebugAndInfoLogs("they are not equal"); 

    return 1; 

    } 

    } 

     

    In Qualitia 8.0.0: 

     

    public AcionResponse EqualStrings(String a, String b) 

    { 

    ActionResponse actionResponse = getActionResponse(); 

    if(a.equals(b)) 

    { 

    actionResponse.setMessage("they are equal"); 

    actionResponse.setExecutionResult(ExecutionResult.PASSED); 

    return actionResponse; 

    } 

    else 

    { 

    actionResponse.setMessage("they are not equal"); 

    actionResponse.setExecutionResult(ExecutionResult.FAILED); 

    return actionResponse; 

    } 

    } 

 

11) getStepId()  

    = This method is used to get the step ID. 

    this is an alternative to Controller.strStepID 

     

    for example, if the user wants to get the ID of current step being executed, he can do it as: 

     

    In earlier versions: 

        String stepid = Controller.strStepID; 

    In Qualitia 8.0.0: 

        String stepid = getStepId(); 

12) getTaskName() 

    = This method is used to get the name of the current task which is being executed. 

    this is an alternative to Controller.taskName 

     

    for example, if the user wants to get the name of current task being executed, he can do it as: 

     

    In earlier versions: 

        String Taskname= Controller.taskName; 

    In Qualitia 8.0.0: 

        String Taskname = getTaskName(); 

  

13) getTestCaseName() 

    = This method is used to get the name of current TC being executed.  

    this is an alternative to Controller.testCaseName 

     

    for example, if the user wants to get the name of current testcase being executed, he can do it as: 

     

    In earlier versions: 

        String TCname = Controller.testCaseName; 

    In Qualitia 8.0.0: 

        String TCname = getTestCaseName(); 

 

14)getTestCaseNameWithoutSpecialChars() 

    = This method is used to get the name of current TC being executed, without special characters like escape character(~). 

    this is an alternative to Controller.testCaseNameWithoutSpecialChars. 

     

    for example, if the user wants to get the name of current testcase being executed, he can do it as: 

     

    In earlier versions: 

        String TCname= Controller.testCaseNameWithoutSpecialChars; 

    In Qualitia 8.0.0: 

        String TCname = getTestCaseNameWithoutSpecialChars(); 

 

15)getScenarioName() 

    = This method is used to  get the name of scenario  being executed 

    this is an alternative to Controller.scenarioName 

     

    for example, if the user wants to get the name of current scenario being executed, he can do it as: 

     

    In earlier versions: 

        String scenarioName = Controller.scenarioName; 

    In Qualitia 8.0.0: 

        String scenarioName = getScenarioName(); 

 

16) getSuiteName() 

    = This method is used to  get the name of current suite being executed 

    this is an alternative to Controller.suiteName 

     

    for example, if the user wants to get the name of current suite being executed, he can do it as: 

     

    In earlier versions: 

        String suiteName = Controller.suiteName; 

    In Qualitia 8.0.0: 

        String suiteName = getSuiteName(); 

 

17) getObjectID() 

    = This method is used to  get current object Id. 

    This is an alternative to Controller.strObjectID. 

  

    for example, if the user wants to get the ID of current object on the browser where he wants to set some value, he can do it as: 

     

    In earlier versions: 

        String objectID = Controller.strObjectID; 

    In Qualitia 8.0.0: 

        String objectID = getObjectID(); 

 

 

18) getIterationFolderPath() 

    = This method is used to get the Iteration folder path i.e. where the report related data is stored. 

    The default value is "C:\Users\user.name\AppData\Local\Qualitia\WD\Client\ResultPath" 

    this is an alternative to Controller.ITERATION_FOLDER_PATH 

     

    for example, if the user wants to get the folder path where all the report related data is kept, he can do it as:  

  

    In earlier versions:  

        String itrFolderPath = Controller.ITERATION_FOLDER_PATH;  

    In Qualitia 8.0.0:  

        String itrFolderPath = getIterationFolderPath(); 

 

19) getSuitesDir() 

= This method is used to get the suite Directory i.e. the folder path where all the JSON files are present. This is the same as provided in config/startupSettings.json 

 

20) getMobileURL 

=     This method is used to get appium server URL where appium server is hosted.  

    This is an alternative to GLOBALS.appiumServerURL 

     

    For example, If the user wants to give a messgae regarding connection failure to appium server, he can do this as: 

     

    In earlier versions: 

        public String APPIUM_NOT_RUNNING = "Failed to connect to Appium Server at " + 

            GLOBALS.appiumServerURL + ". Please verify Appium server host and port and make sure that " + 

            "it is started before executing the test case."; 

     

    In Qualitia 8.0.0: 

        public static String APPIUM_NOT_RUNNING = "Failed to connect to Appium Server at " + 

            getMobileURL()+ ". Please verify Appium server host and port and make sure that " + 

            "it is started before executing the test case."; 

 

21) getCI_Tool() 

=     This method is used to get the value of CI_TOOL which is provided in execution profile. 

    This is an alternative to GLOBALS.CONFIG_CITOOL 

  

    For example, if a user wants to get an Instance of particular CI Tool, he can do it as: 

     

    In earlier versions: 

        private static final CIHandler _CIH = CIFactory.getInstance(GLOBALS.CONFIG_CITOOL); 

         

    In Qualitia 8.0.0: 

         private static final CIHandler _CIH = CIFactory.getInstance(getCI_Tool()); 

 

22) getTestCaseCounter() 

= this method is used to get the iteration number of Testcase being executed. 

This is an alternative to Controller.testCaseCounter 

 

23) isDesktopExecution() 

= This method is used to decide if the Execution platform is Desktop or not. It returns true when the executing platform is Desktop and returns false when execution platform is Mobile. 

This is an alternative to QualitiaSelenium.isDesktopExecution 

  

For example: If user wants to do a particular operation when testcase is running on Desktop, he can do it as:   

  

   

  

     In earlier versions:   

        if(QualitiaSelenium.isDesktopExecution)   

        {   

        //Desktop related operation   

        }   

  

  

     In Qualitia 8.0.0:   

        if(isDesktopExecution())   

  

        {   

  

        //Desktop related operation   

  

  

        }   

 

24) getProjectName() 

=     This method is used to get the project name as specified in execution profile. 

    This is an alternative to GLOBALS.CONFIG_PROJECT 

 

25)  getUserName 

=  This method is used to get the user name as specified in execution profile.  

    This is an alternative to GLOBALS.CONFIG_USERNAME  

  

26) getBuildNum 

=  This method is used to get the Build number as specified in execution profile.  

    This is an alternative to GLOBALS.CONFIG_BUILD_NUMBER  

27) getReleaseNum 

=  This method is used to get the release number as specified in execution profile.  

    This is an alternative to GLOBALS.CONFIG_RELEASE_NUMBER 

 

28)  getCreateInfoLog() 

= This method is used to get the value of "CreateInfoLog" property as specified in execution profile.   

    If the value is true, then Info Log file is created and and if it is false then the Info Log file is not created. 

     

29) getCreateDebugLog() 

=    This method is used to get the value of "CreateDebugLog" property as specified in execution profile.   

    If the value is true, then Debug Log file is created and will be visible in report and if it is false then the Debug Log file is not created. 

     

30) getCreateErrorLog() 

=     This method is used to get the value of "CreateErrorLog" property as specified in execution profile.   

    If the value is true, then Error Log file is created and will be visible in report and if it is false then the Error Log file is not created. 

 

31) getShowReportAfterExec() 

=     This method is used to get the value of "ShowReportAfterExec" property as specified in execution profile.   

    If the value is true, then report is opened in a new browser window and if it is false then it is not opened in a browser window. The report is generated and stored in Iteration folder but it is not opened automatically. 

 

32) getKeywordId() 

=     This method is used to  get the ID of current function/action being executed. 

    this is an alternative to Controller.strKeywordID 

 

33) getActionQClass() 

=     This method is used to  get the base class of current function/action being executed. 

    this is an alternative to Controller.strActionQClass 

 

34) getKeywordName() 

=     This method is used to  get the name of current function/action executing. 

    this is an alternative to Controller.strKeywordName 

 

35) isCustomAction() 

=     This method is used to decide if the currently executing action is custom action or qualitia action. 

    It returns true when the executing action is custom action and returns false when it is qualitia action. 

    this is an alternative to QualitiaSelenium.isCustomAction. 

     

    for example, if a user wants to do a particular operation depending whether the current executing action is custom action or not, he can do it as: 

     

    In earlier versions: 

        if(QualitiaSelenium.isCustomAction) 

        {//operation} 

    In Qualitia 8.0.0: 

        if(isCustomAction()) 

        {//operation} 

 

36) getCapturePassImage 

=     This method is used to get the value of "CapturePassImage" property as specified in execution profile.   

    If the value is true, then screenshots are captured for steps that have executionResult as PASSED and if it is false then screenshots are not captured for PASSED steps. 

     

37) getCaptureFailImage 

=     This method is used to get the value of "CaptureFailImage" property as specified in execution profile.   

    If the value is true, then screenshots are captured for steps that have executionResult as FAILED and if it is false then screenshots are not captured for FAILED steps. 

     

38) getCaptureDefectImage 

=     This method is used to get the value of "CaptureDefectImage" property as specified in execution profile.   

    If the value is true, then screenshots are captured for steps that have executionResult as DEFECT and if it is false then screenshots are not captured for DEFECT steps. 

 

39) getHeadlessMode() 

= This method is used to get the value of "HeadlessMode" property as specified in execution profile. If it return true then the browser is opened in headless mode else it is not. 

This is an alternative to GLOBALS.CONFIG_HEADLESSMODE. 

 

40) getFailStepOnBrowserScreenshotFailure 

=   This method is used to get the value of "FailStepOnBrowserScreenshotFailure" property as specified in execution profile.    

  

    If the value is true, then if screenshots are not captured properly for PASSED steps  then they are changed to FAILED.If it is false then even if screenshots are not captured for PASSED steps, execution continues normally. 

 

41) getQualitiaPropValue(String key) 

= this method is used to get value of any Qualitia property as specified in execution profile. Here key is the Qualitia property name.  

  

For example, if the user wants to know the value of "MobilePlatform", he can do it as: 

String mobilePaltform = getQualitiaPropValue("MobilePlatform"); 

 

42) getSelectedWaitMode() 

= This method is used to get the value of "WaitMode" property as specified in execution profile.   

The values can either be "EXPLCIT" or "IMPLICIT". 

This is an alterantive to QualitiaSelenium.getSelectedWaitMode(). 

  

for example, if a user wants to do a certain task when waitmode is IMPLICIT, he can do it as: 

  

In earlier versions: 

if(QualitiaSelenium.getSelectedWaitMode() == CONSTANTS.WaitMode.IMPLICIT){ 

                // task  

            } 

  

In Qualitia 8.0.0: 

if(getSelectedWaitMode() == CONSTANTS.WaitMode.IMPLICIT){ 

                // task  

            } 

 

43) getIntervalTimeOut() 

= This method is used to get the value of "IntervalTimeOut" property as specified in execution profile.   

This is an alternative to QualitiaMobile.IntervalTimeOut   

 

44) shutdownMobileDriverSession() 

= This method is used for mobile driver cleanup process. 

This is an alternative to QualitiaMobile.quitMobileDriver().  

For example if a user has performed mobile operations using mobile driver and now wants to stop the driver, he can do itas : 

In earlier versions: 

QualitiaMobile.quitMobileDriver(); 

In Qualitia 8.0.0: 

 shutdownMobileDriverSession() 

 

45) getSelectFrame() 

= This is an alternative to Controller.EXECUTION_TESTCASES(Controller.testCaseCounter).getSelectFrame() 

 

46) getBrowserName()  

= This method is used to get the value of "BrowserName" property as specified in execution profile.    

The values can be "googleChrome, firefox,iexplorer and safari". 

This is an alternative to QualitiaSelenium.getBrowser() 

  

for example, if a user wants to perform certain task on firefox browser, he can do it as: 

  

In earlier versions: 

if (QualitiaSelenium.getBrowser().equalsIgnoreCase(CONSTANTS.FIREFOX) 

//task 

In Qualitia 8.0.0: 

  if (getBrowserName().equalsIgnoreCase(CONSTANTS.FIREFOX) 

//task 

 

47) getParamTypes() 

= this method is used to get the parameter types of an action. 

This is an alternative to QualitiaTestCase.paramTypes 

  

For example, if a user wants to call a method using reflection, he can do it as: 

  

In earlier versions: 

    Method m = class.getMethod(functionName, QualitiaTestCase.paramTypes); 

In Qualitia 8.0.0: 

    Method m = class.getMethod(functionName, getParamTypes()); 

 

48) getElementHighlighter 

= this method is used to get the object of elementHighlighter class. It is used to highlight and unhighlight elements in browser.  

  

For example, if a user wants to highlight and unhighlight and element, he can do it as: 

  

In earlier versions: 

    FwUtil.highlightElement(),FwUtil.unhighlightElement() 

In Qualitia 8.0.0: 

    getElementHighlighter.highlight(),getElementHighlighter.unhighlight() 

 

49) getKeywordFunction() 

= This method is used to get the current function/action. 

    this is an alternative to Controller.strKeywordFunction 

 

50) getKeywordQFunction() 

= This method is used to get the Qfunction for particular keyword. 

This is an alternative to Controller.strKeywordQFunc 

 

51) isMobileDriverAlreadyLaunched() 

= This method is used to know if the mobile driver is already launched or not.  

If it returns true then the mobile driver has been launched else it is empty or its cleanup process is done. 

This is an alternative to QualitiaMobile.isDriverAlreadyLaunched(). 

  

For example, if a user wants to print a message that Appium driver cannot be launched by checking, he can do it as: 

  

In earlier versions: 

    if (QualitiaMobile.isDriverAlreadyLaunched()) { 

            _LOGGER.info("Appium Driver is already launched.");} 

In Qualitia 8.0.0: 

    if (isMobileDriverAlreadyLaunched()) { 

            _LOGGER.info("Appium Driver is already launched.");} 

 

52) getCurrentMobileAppType() 

= This method is used to get which type of mobile app is being used. The values can be "NATIVE" or "HYBRID". 

This is an alternative to QualitiaMobile.getCurrentMobileAppType() 

 

53) setWebPlatformSession(PlatformSession webPlatformSession) 

= this method is used to set a new web driver. This is an alternative to QualitiaSelenium.setDriver() 

  

for example, if the user wants to set a new browser web driver, he can do it as: 

In Qualitia 8.0.0: 

        PlatformSessionBuilder platformSessionBuilder = new PlatformSessionBuilder(PlatformType.BROWSER_NAME);             

        Future<PlatformSession> webDriverSessionFuture = platformSessionBuilder.buildAsync();     

        setWebPlatformSession(webDriverSessionFuture.get());     

  

54) setMobilePlatformSession(PlatformSession mobilePlatformSession) 

this method is used to set a new mobile driver. This is an alternative to QualitiaMobile.setDriver() 

  

for example, if the user wants to set a new browser mobile driver, he can do it as: 

In Qualitia 8.0.0: 

        PlatformSessionBuilder platformSessionBuilder = new PlatformSessionBuilder(PlatformType.BROWSERNAME);             

          Future<PlatformSession> mobileDriverSessionFuture = platformSessionBuilder.buildAsync();     

          setMobilePlatformSession(mobileDriverSessionFuture.get());     

 

55) setActionLevelPageLoadTimeout(String pageLoadTimeout) 

= This method is used to set the value of "ActionLevelPageLoadTimeout" property. 

This is an alternative to QualitiaSelenium.setActionLevelPageLoadTimeout() 

 

56) getPageLoadTimeout() 

=  This method is used to get the value of "PageLoadTimeout" property.  

This is an alternative to QualitiaSelenium.getPageLoadTimeout() 

 

57) getMaximumFindObjectTimeImplicit() 

=  This method is used to get the value of "MaximumFindObjectTimeImplicit" property.  

This is an alternative to QualitiaSelenium.MaximumFindObjectTimeImplicit() 

 

58) getMaximumFindObjectTimeExplicit() 

=  This method is used to get the value of "MaximumFindObjectTimeExplicit" property.  

This is an alternative to QualitiaSelenium.MaximumFindObjectTimeExplicit() 

 

59) getPollingInterval() 

=  This method is used to get the value of "PollingInterval" property.  

This is an alternative to QualitiaSelenium.getPollingInterval()  

  

60) getMaximumFindObjectTimeForMobile() 

=  This method is used to get the value of "MaximumFindObjectTimeForMobile" property.  

This is an alternative to QualitiaSelenium.maximumFindObjectTime()  

 

61) getScreenCaptureMode() 

= This method is used to get the value of "ScreenCaptureMode" property as specified in execution profile. 

Values can be BROWSER or DESKTOP. 

This is an alternative to GLOBALS.CONFIG_SCREEN_CAPTURE_MODE 

 

62) getIntervalTimeOutForMobile() 

= This method is used to get the value of IntervalTimout property.  

This is an alternative to QualitiaMobile.IntervalTimeOut() 

 

63) getMobileUDID() 

= This method is used to get the value of "MobileUDID" as specified in execution profile. 

This property is used to specify the mobile on which the testcase should be run. 

This is an alternative to GLOBALS.mobileUDID. 

 

 

68) getMobileBrowser() 

= This method is used to get the value of "MobileBrowser" as specified in execution profile. 

This property is used to specify the mobile browser on which the testcase should be run. 

This is an alternative to GLOBALS.mobileBrowserName. 

 

69) getAppiumServerURL() 

= This method is used to get appium server URL where appium server is hosted.   

  

    This is an alternative to GLOBALS.appiumServerURL  

  

      

  

    For example, If the user wants to give a messgae regarding connection failure to appium server, he can do this as:  

  

      

  

    In earlier versions:  

  

        public String APPIUM_NOT_RUNNING = "Failed to connect to Appium Server at " +  

  

            GLOBALS.appiumServerURL + ". Please verify Appium server host and port and make sure that " +  

  

            "it is started before executing the test case.";  

  

      

  

    In Qualitia 8.0.0:  

  

        public static String APPIUM_NOT_RUNNING = "Failed to connect to Appium Server at " +  

  

            getAppiumServerURL()+ ". Please verify Appium server host and port and make sure that " +  

  

            "it is started before executing the test case."; 

 

70) isOptimizationModeEnabled() 

= This method is used to get the value of "OptimizationMode" property as specified in execution profile. 

If it returns true then OptimizationMode is enabled else it is not.  

This is an alternative to GLOBALS.CONFIG_OPTIMIZATION_MODE. 

  

71) isIgnoreAngularSynchronization) 

= This method is used to get the value of "IgnoreAngularSynchronization" property as specified in execution profile. 

If it returns true then AngularSynchronization is ignored else it is not.  

This is an alternative to GLOBALS.CONFIG_IGNORE_ANGULAR_SYNCHRONIZATION 

 

72) isExecutionHighlight() 

= This method is used to get the value of "ExecutionHighlight" property as specified in execution profile. 

If it returns true then ExecutionHighlight is enabled else it is not.  

This is an alternative to GLOBALS.CONFIG_IS_EXECUTION_HIGHLIGHT 

 

73) getAutoITPath() 

= This method is used to get the value of "AutoITPath" property as specified in execution profile. 

Default value is "C:\\Program Files (x86)\\AutoIt3". 

This is an alternative to GLOBALS.CONFIG_AUTOITPATH 

  

74) getExecutionResultPath() 

= This method is used to get the value of "ExecutionResultPath" property as specified in execution profile. 

It returns the folder path where Execution Result i.e. Report regarding particular suite execution is stored. 

 

75) getExecutionEnvironment() 

=  This method is used to get the value of "ExecutionEnvironment" property as specified in execution profile.  

    Value can either be "LOCAL" or "REMOTE". LOCAL means local machine and REMOTE includes SauceLabs,Perfecto, TestObject etc. 

    This is an alternative for GLOBALS.WEB_EXECUTION_ENVIRONMENT 

     

    For example, if a user wants to a perform a sauce related task, he can do it as: 

     

    In earlier versions: 

        if (GLOBALS.WEB_EXECUTION_ENVIROMENT.equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment()) 

        {//task} 

    In Qualitia 8.0.0: 

        if (getExecutionEnvironment().equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment()) 

        {//task} 

         

76) getRemoteURL() 

= This method is used to get the value of "RemoteURL" property as specified in execution profile.  

This is an alternative to GLOBALS.CONFIG_REMOTE_URL.  

It is used to get URL of remote environment like Sauce, PErfecto etc, if ExecutionEnvironment is set to remote. 

  

77) getNewBrowserMode() 

= This method is used to get the value of "NewBrowserMode" property as specified in execution profile. 

    Values can either be "PerTC" or "PerSuite". If the value is PerTC then all the testcases in the suite are independent from each other. If the value is PerSuite then all the testcases are dependent on each other. 

    This is an alternative to QualitiaSelenium.getExecutionMode() 

    In earlier versions: 

        QualitiaExecMode= PT/PS 

    In Qualitia 8.0.0:  

        NewBrowserMode = PerTC/PerSuite 

  

 78) getMobileExecutionEnvironment() 

= This method is used to get the value of "MobileExecutionEnvironment" property as specified in execution profile.  

    Value can either be "testObject","perfectomobile","perfectoweb","saucemobile","sauceweb". 

    This is an alternative for GLOBALS.mobileExecutionEnvironment 

     

    For example, if a user wants to a perform a sauce related task, he can do it as: 

     

    In earlier versions: 

        if (GLOBALS.mobileExecutionEnvironment.equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment()) 

        {//task} 

    In Qualitia 8.0.0: 

        if (getMobileExecutionEnvironment().equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment()) 

        {//task} 

 

79) getMobilePlatform 

= This method is used to get the value of "MobilePlatform" property as specified in execution profile.   

Values can either be IOS or Android. 

This is an alternative to GLOBALS.mobilePlatform  

  

For example, if a user wants to decide which platform is being used for the testcase, he can do it as: 

  

In earlier versions: 

if (GLOBALS.mobilePlatform == MobilePlatformName.ANDROID) { 

            System.out.print("ANDROID"); 

  

        } else if (GLOBALS.mobilePlatform == MobilePlatformName.IOS) { 

            System.out.print("IOS"); 

        } 

         

In Qualitia 8.0.0: 

if (getMobilePlatform() == MobilePlatformName.ANDROID) { 

            System.out.print("ANDROID"); 

  

        } else if (getMobilePlatform== MobilePlatformName.IOS) { 

            System.out.print("IOS"); 

        } 

 

80) getQualitiaServerURL 

= This method is used to get the value of "QaulitiaServerURL" property as specified in execution profile. 

This is the URL where Qualitia Server is hosted. 

This is an alternative to GLOBALS.CONFIG_QUALITIASERVERURL 

  

81) getProductVersion() 

= This method is used to get the value of "ProductVersion" property as specified in execution profile. 

This is the version of Qualitia being used. 

 

82) isCurrentQFunction(String func) 

= This method is used to decide if the provided func is currentlyt executing or not. 

qIt returns true if current Action running is same as func given in paramter else it returns false. 

This is an alternative to CommonUtil.isCurrentQFunction() 

 

 

88) getDefaultWebExecutionPlatform 

= This method is used to get the value of "DefaultWebExecutionPlatform" property as specified in execution profile. 

Value can either be MOBILE or DESKTOP. The value of this property decides on which platform will the web testcase be executed.  

It can be used in hybrid testcase to know which platform is being used currently. 

This is an alternative to GLOBALS.defaultWebExecutionPlatform 

  

89) getMobileNativeObjectsSyncTime 

= This method is used to get the value of "MobileNativeObjectsSyncTime" property as specified in execution profile. 

  

90) getBrowserBinaryPath 

= This method is used to get the value of "BrowserBinaryPath" property as specified in execution profile. 

  

91) getWindowsAuthentication 

= This method is used to get the value of "WindowsAuthentication" property as specified in execution profile. 

  

92) getReportPath 

= This method is used to get the value of "ReportPath" property as specified in execution profile. 

This is an alternative to GLOBALS.CONFIG_REPORTPATH 

  

93) getBrowserProfilePath 

= This method is used to get the value of "BrowserProfilePath" property as specified in execution profile. 

This is an alternative to GLOBALS.CONFIG_CUSTOM_PROFILEPATH 

  

94) getToolName 

= This method is used to get the value of "ToolName" property as specified in execution profile. 

This is an alternative to GLOBALS.CONFIG_TOOLNAME 

  

95) getExecutionType 

= This method is used to get the value of "ExecutionType" property as specified in execution profile. 

This is an alternative to GLOBALS.CONFIG_EXECUTION_TYPE 

 

96) getGridPlatform 

= this method is used to get the value of "GridPlatform" property as specified in execution profile. 

This is an alternative to GLOBALS.GRID_PLATFORM. 

  

97) getCurrentWebExecutionPlatform 

= this method is used to get the current platform on which the Testcase is executing. It can either be MOBILE or DESKTOP. 

This is an alternative to QualitiaTestCase.getLastDriverTypeUsed() 

  

98) setCurrentWebExecutionPlatform 

= this method is used to set the current platform on which the Testcase must execute. It can either be MOBILE or DESKTOP. 

This is an alternative to QualitiaTestCase.setLastDriverTypeUsed() 

  

99)updateWebExecutionPlatformSystemVariables 

= This method is  used to update web execution platform  in system variables. 

  

100)getLastDriverTypeUsed 

= this method is used to get the value of driver type used. It can be Web or Mobile. 

This is an alternative to QualitiaTestCase.getLastDriverTypeUsed() 

  

101)setLastDriverTypeUsed 

= this method is used to set the value of driver type used. It can be Web or Mobile. 

This is an alternative to QualitiaTestCase.setLastDriverTypeUsed() 

 

102) resolveSpecialCharactersAndVariablesAndEscape 

= this method is used to remove all the special characters and escape characters from expression provided in conditions like IF. 

This is an alternative to FwUtil.resolveSpecialCharactersAndVariablesAndEscape(). 

  

103)resolveSpecialCharactersAndVariables 

= this method is used to remove all the special characters and escape characters from expression provided in conditions like IF. 

This is an alternative to FwUtil.resolveSpecialCharactersAndVariables(). 

  

104)resolveObjectProperties 

= This method is used to resolve object properties. 

  

105)getExecutionMode 

= this method is used to get the Execution Mode value. Value can either be PS(PerSuite) or PT (PerTestCase). 

This is an alternative to QualitiaSelenium.getExecutionMode() 

 

 

  • No labels