...
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.
...
For example, if a user wants to write a custom action for checking two strings are equal, he can do it as:
In earlier versionsIn Qualitia 8.0.0:
public int AcionResponse EqualStrings(String a, String b)
{
ActionResponse actionResponse = getActionResponse();
if(a.equals(b))
{
DataLoggeractionResponse.writeToDebugAndInfoLogssetMessage("they are equal");
return 0actionResponse.setExecutionResult(ExecutionResult.PASSED);
return actionResponse;
}
else
{
DataLoggeractionResponse.writeToDebugAndInfoLogssetMessage("they are not equal");
return 1actionResponse.setExecutionResult(ExecutionResult.FAILED);
return actionResponse;
}
}
In Qualitia 8.0.0earlier versions:
public AcionResponse int EqualStrings(String a, String b)
{
ActionResponse actionResponse = getActionResponse(); if(a.equals(b))
{
actionResponseDataLogger.setMessagewriteToDebugAndInfoLogs("they are equal");
actionResponse.setExecutionResult(ExecutionResult.PASSED); return actionResponsereturn 0;
}
else
{
actionResponseDataLogger.setMessagewriteToDebugAndInfoLogs("they are not equal");
actionResponse.setExecutionResult(ExecutionResult.FAILED); return actionResponsereturn 1;
}
}
...
getStepId()
= This method is used to get the step ID.
...
for example, if the user wants to get the ID of current step being executed, he can do it as:
In earlier versions In Qualitia 8.0.0:
String stepid = Controller.strStepIDgetStepId();
In Qualitia 8.0.0earlier versions:
String stepid = getStepId()Controller.strStepID; 12)
getTaskName()
= This method is used to get the name of the current task which is being executed.
this This is an alternative to Controller.taskName
for For example, if the user wants to get the name of current task being executed, he can do it as:
In earlier versionsIn Qualitia 8.0.0:
String Taskname = Controller.taskName; In Qualitia 8.0.0getTaskName();
In earlier versions:
String Taskname= getTaskName()Controller.taskName; 13)
getTestCaseName()
= This method is used to get the name of current TC being executed.
this This is an alternative to Controller.testCaseName
for testCaseName
For example, if the user wants to get the name of current testcase being executed, he can do it as:
In earlier versions:
In Qualitia 8.0.0:
String TCname = Controller.testCaseName; getTestCaseName();
In Qualitia 8.0.0earlier versions:
String TCname = getTestCaseName()Controller.testCaseName;
14)getTestCaseNameWithoutSpecialChars()
...
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.
...
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.
...
_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()
...
setWebPlatformSession(webDriverSessionFuture.get());
54)
setMobilePlatformSession(PlatformSession mobilePlatformSession)
this method is used to set a new mobile driver. This is an alternative to QualitiaMobile.setDriver()
...
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 his 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()
...
getMaximumFindObjectTimeExplicit()
= This method is used to get the value of "MaximumFindObjectTimeExplicit" property.
This is an alternative to QualitiaSelenium.MaximumFindObjectTimeExplicit()
...
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().
...
getScreenCaptureMode()
= This method is used to get the value of "ScreenCaptureMode" property as specified in execution profile.
...
This is an alternative to GLOBALS.CONFIG_SCREEN_CAPTURE_MODE
62) MODE.
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 is an alternative to GLOBALS.mobileUDID.
...
getMobileBrowser()
= This method is used to get the value of "MobileBrowser" as specified in execution profile.
...
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 For example, If the user wants to give a messgae regarding connection failure to appium server, he can do this as:
In earlier versions In Qualitia 8.0.0:
public static String APPIUM_NOT_RUNNING = "Failed to connect to Appium Server at " +
GLOBALS.appiumServerURL getAppiumServerURL()+ ". Please verify Appium server host and port and make sure that " +
...
"it is started before executing the test case.";
In Qualitia 8.0.0earlier versions:
public static String APPIUM_NOT_RUNNING = "Failed to connect to Appium Server at " +
getAppiumServerURL()GLOBALS.appiumServerURL + ". Please verify Appium server host and port and make sure that " +
...
"it is started before executing the test case.";
70) isOptimizationModeEnabled
isOptimizationModeEnabled()
= This method is used to get the value of "OptimizationMode" property as specified in execution profile.
...
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.
...
This is an alternative to GLOBALS.CONFIG_IGNORE_ANGULAR_SYNCHRONIZATION SYNCHRONIZATION. 72)
isExecutionHighlight()
= This method is used to get the value of "ExecutionHighlight" property as specified in execution profile.
...
This is an alternative to GLOBALS.CONFIG_IS_EXECUTION_HIGHLIGHT HIGHLIGHT. 73)
getAutoITPath()
= This method is used to get the value of "AutoITPath" property as specified in execution profile.
...
This is an alternative to GLOBALS.CONFIG_AUTOITPATH
74) AUTOITPATH.
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.
...
For example, if a user wants to a perform a sauce related task, he can do it as:
In earlier versionsQualitia 8.0.0:
if (GLOBALS.WEB_EXECUTION_ENVIROMENT.getExecutionEnvironment().equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment())
{//task}
In Qualitia 8.0.0earlier versions:
if (getExecutionEnvironment()GLOBALS.WEB_EXECUTION_ENVIROMENT.equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment())
{//task}
76)
getRemoteURL()
= This method is used to get the value of "RemoteURL" property as specified in execution profile.
...
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.
...
This is an alternative to QualitiaSelenium.getExecutionMode()
In earlier versions:
QualitiaExecMode= PT/PS
()
In Qualitia 8.0.0:
NewBrowserMode = PerTC/PerSuite
78) getMobileExecutionEnvironment
In earlier versions:
QualitiaExecMode= PT/PS
getMobileExecutionEnvironment()
= This method is used to get the value of "MobileExecutionEnvironment" property as specified in execution profile.
...
For example, if a user wants to a perform a sauce related task, he can do it as:
In earlier versionsIn Qualitia 8.0.0:
if (GLOBALS.mobileExecutionEnvironmentgetMobileExecutionEnvironment().equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment())
{//task}
In Qualitia 8.0.0 In earlier versions:
if (getMobileExecutionEnvironment()GLOBALS.mobileExecutionEnvironment.equalsIgnoreCase(ExecutionEnvironment.Sauce.getEnvironment())
{//task}
...
getMobilePlatform
= This method is used to get the value of "MobilePlatform" property as specified in execution profile.
...
For example, if a user wants to decide which platform is being used for the testcase, he can do it as:
In earlier versionsIn Qualitia 8.0.0:
if (getMobilePlatform(GLOBALS.mobilePlatform ) == MobilePlatformName.ANDROID) {
System.out.print("ANDROID");
} else if (GLOBALS.mobilePlatform getMobilePlatform== MobilePlatformName.IOS) {
System.out.print("IOS");
}
In Qualitia 8.0.0earlier versions:
if (getMobilePlatform() GLOBALS.mobilePlatform == MobilePlatformName.ANDROID) {
System.out.print("ANDROID");
} else if (getMobilePlatformGLOBALS.mobilePlatform == 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 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.
...
isCurrentQFunction(String func)
= This method is used to decide if the provided func is currentlyt executing or not.
...
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.
...
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.
...
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 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 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).
...