Skip to content

testing-blaze/testingblazeframework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TBS logo

Maven Central Apache V2 License PRs welcome GitHub issues open Maven Central Parent

An Intelligent BDD Test Automation Framework - 'Let the tests heal at own'


About The Project

The Testing Blaze Automation Solution brings the universe of open source technologies embedded and architectured in an innovative way to make the automated testing experience easy , interactable and flakiless.

The key features are:

  • Self Healing of Tests (To Recover from Attribute changes) - Requires a Hosting Server on Premises/Cloud

  • Dependency Injection Controlled Architecture. No worries to manage object instances

  • Automatic Runner files generation during execution. No hastle to maintane Runners

  • Intelligent Element Processing (To Handle Dynamic loading of Applications)

  • Automatic Switching to Contexts/IFrames/Tabs , Auto Scrolling , Highlighting Element under Action

  • Plug And Play Framework (Just use framework dependency to start writing tests in your project)

  • Live Reporting Portal Integration (Provides execution summary and categorise failuers into bugs and maintenance)

  • Detailed Automation Report (Generated with each execution and contains all logs and screenshots)

  • Built In Gherkins And Cucumber Integrated Parameterization

  • Tests written for a computer browser can also be executed on a mobile device browser without any change to tests (Same DOM only).

Built With

Integrated With

Self healing module which is built with

Supports

• Devices: Computers, Mobiles, Tablets, Cloud, Docker
• Execution Types: Parallel, Sequential, Browser UI, Browser headless
• Application Types: Browser Based (Angular/HTML), Mobile App Based (Native/Hybrid)
• Browsers: Chrome, Firefox, Edge, IE, Safari

Getting Started

Setting up the project is very simple and does not require any special configurations. You can simply clone a sample project and start working with it.

Installation

  1. Java 11
  2. Maven
  3. Appium Server (For mobile testing only)
After your installations, simply copy the parent and dependency of framework from maven central to your POM. See sample project from below link.

How to use it ?

The framework offers a gherkin style of code writing which makes each line of code readable and it also provides access to all type of devices,libraries from a single line of code.

All libraries can be accessed in any Java class using: I.amPerforming()
• Reach out to your page object class and write I.amPerforming()
• Each library has relevant utilities inside it to access and use.
• Each library method will show description of what it does.
• The code is human readable.

How to click / text input?

I.amPerforming().click().on(ByUsing.xpath("//"));
I.amPerforming().textInput().in(ByUsing.xpath("//"),inputText);

• This will perform the click/input on any device.
• It will also perform certain processing to ensure element is ready to click and also switch to any frame if needed.
• It is also accompanied with retries in certain situations at own.

Interact with selenium, appium abs self healing with single type "ByUsing":

This type gives access to all locator types including selenium , android , ios and self healing. Example: ByUsing.xpath("//"")

Using Self healing feature:

• Get the credentials after authorization.
• Login to the provided portal for locator management.
• Use is in your code with ByUsing.healingXpathName(LocatorName).
• If Dom will change, test will auto heal.
• Example can be seen on this link.

Run Your Test:

Open command line/Terminal/IDE. Reach to Project root and execute below as required

Standard Command: mvn clean verify -Dtags=@testCaseTag

1- On Local Browser:
Standard Command +
Choose Browser:
-Ddevice=chrome/firefox/ie/safari

2- On Jenkins/Any Engine:
Standard Command +
Choose Browser:
-Ddevice=chrome/firefox/ie/safari

3- On Cloud (SauceLab/BrowserStack):
Standard Command +
Choose Browser:
-Ddevice=chrome/firefox/ie/safari
-Dhub=https://:@ondemand.saucelabs.com:443

4- On Mobile: [Appium Server will be started and stopped automatically]
Standard Command +
-Dhub=http://IP_For_Appium:Port [http://0.0.00:4723]
-DdeviceName= Samsung / Iphone 11 (Mobile Name) Default:Samsun/iPhone 8 Plus -Dversion= 11.0/9.0 (Android or IOS Versions) Default:8.0/11.4 For Browser:
-Ddevice=android/Ios (Default: Chrome / safari)
For App:
-Ddevice=android
-DappName=appname
Note: Place the mobile app in “mobileApp” folder in project root. Add “appConfig.properties” in same folder with information of appPackage and appActivity for Android.

5- On Docker: [Docker will be started and stopped automatically]
[Download images and name them as selenium-chrome or selenium-Browser-Name]
Standard Command +
-Ddocker=true
-Dhub=http://IP_For_Docker:Port [http://0.0.00:4444]
For Browser:
-Ddevice=android (Chrome is default browser)
For App:
-Ddevice=android
-DappName=appname
->If you want to stop the container after every test then call a method stopDocker in @Before tag.

6- On Zalenium Docker Hub: [Run your test cases on Zalenium Hub]
Pull the selenium docker image :

docker pull elgalu/selenium

Pull the Zalenium Image :

docker pull dosel/zalenium

After downloading above images, run zalenium using following command

docker run --rm -ti --name zalenium -p 4444:4444 \
      -v /var/run/docker.sock:/var/run/docker.sock \
      -v /tmp/videos:/home/seluser/videos \
      --privileged dosel/zalenium start

Standard Command +
-Dhub=http:localhost:4444/

7. On Browser in mobile view :

To run the test cases in chrome browser with mobile view, we can use following command.

mvn clean verify -Dtags="@yourTagToRun" -DbrowserMode=mobile

Run test case in custom configuration of a particular mobile emulator in browser

mvn clean verify -Dtags="@test" -browserMode=mobile -DcustomMobileEmulator=true -Dwidth=300 -Dheight=900

Run test case in particular emulator's default configuration such as iPad mini and so on.

mvn clean verify -Dtags="@test" -DbrowserMode=mobile -DdeviceName="iPad Mini"

There are multiple devices available to load any page in mobile view. You can find it in Developer tool of chrome browser. Go to Developer tool -> Select toggle device toolbar(small mobile like icon) -> Under dimentions, you will find different emulators available.

Other Options:

• Browser Mode: -DbrowserMode=incognito
• Switch Environemnts: -Denv=qa
• Select OS: - -Dplatform=windows/mac -Dversion=10
• Headless Mode: -Dheadless=true
• Parallel Execution: -Dthreads=10/AnyNumber
• Increase Element Loading Time: -DwaitTime=20
• Record Video: -DrecordVideo=true
• Enable Screen Shots for all: -DenableScreenShotsForAll=true
• Run multiple tags =”@test1 or @test2”
• Skip test/scenario: use @wip on scenario or feature file
• Enable Complete page Screen Shot: -DenableFullScreenShot=true
• Use Specific execution Driver = -DdriverVersion=74
• Use Specific execution Browser = -DbrowserVersion=74
• Slow Down Execution Speed = -DslowDownExecution = 1 (it will be considered 1 second)
• Run a test tag multiple times = -DnumberOfTimesRunTag = 2
• Post test results = -DpostTestResults = tfs/jira
• Publish Analytics Report on Server = -DpublishReport = yes/no
• Set Custom Execution Date = -DsetExecutionDate = tfs/jira
• Enable Screenshots for Soft Assertions failure: -DsoftAssertScreenshot=true

Cucumber Dynamic Parameterization

Saving and retrieving parameters from feature file

Within any step in a feature file you may dynamically adjust the Strings passed to steps at run time. To do so, you can use either of the following formats:
• ---Key:-:Value---
• {Key:Value}

In the section that follows the form {Key:Value} will be used for consistency. But ---Key:-:Value--- has the same functionality in all respects.

1-Adding parameters to locators:

---Key:-:Value--- :

Example:

Add below regex in any of your step in feature file to read parameter and get added to xpath automatically
---PropertiesFileName:-:ParameterNameInPropertiesFile---

2-Passing parameters/values for input:

{Key:Value}

By default, “Key” is interpreted as the name of a file with name “Key.properties”, and the value substituted will by the property value from that file named “Value”. For example, consider the following step:
• I see the text “Value 1: {KPI:Value-1}”

Without dynamic processing, the parameter passed to the Step file would be precisely “Value 1: {KPI:Value-1}.
With dynamic processing, the parameter is modified, and the Step file receives the value “Value 1: ”, where is the property with name “Value-1” in the file “KPI.properties”.

In addition to reading from property files, there are several reserved words which can be passed as the Key, which will perform different processing. They are as follows:

• {SavedValue:ValueKey} - Will substitute the value previously saved in the scenario via a call to “I.amPerforming().propertiesFileOperationsTo().saveValue(ValueKey, theSavedValue)”.
This works exactly as if a call to “I.amPerforming().propertiesFileOperationsTo()getValue(ValueKey) had been made.
• {Username:UserLevel} - Will substitute the username of the user with userLevel “UserLevel”.
“UserLevel” should be the same String that would be passed to the step “I login as ‘userLevel’ user”
• {Password:UserLevel} - The same as Username, except it substitutes the password of the given user.
• {Email:UserLevel} - The same as Username, except is substitues the email of the given user.
Note, for this to work the “getEmail()” method must be added in UsersAndUrl for each individual project.
• {Date:DateFormat} – Will substitute today’s date in the desired format, like dd/MM/yyyy, or MM/dd/yyyy.
• {Date:DateFormat::Modifiers} – The same as previous entry, but date can be modified using a semi-colon delimited list of modifiers. The format for each modifier is “char+int”, “char-int”, or “char=int”.
“char” can be any letter that would be used in DateFormat, and modifies the same part of the date.
(i.e. m=1 sets the minute to 1. M=1 sets the month to 1.)
Modifiers are processed from left to right. So “d=1,M+1,d-1” will set the day to the first of the month, add one to the month, and subtract 1 from the day, resulting in the last day of the current month.

Dynamic parameter usage examples

  1. Given a file named “KPI.properties” exists with the following contents:
    Value-1=This is the first KPI
    Value-2=This is the second KPI
    The following substitution can be made:
    I see the text “The current KPI is: {KPI:Value-2}”
    ↓ I see the text “The current KPI is: This is the second KPI”

  2. Given that the following call has been made earlier in the scenario:
    I.amPerforming().propertiesFileOperationsTo().saveValue (“BudgetPeriodEndDate”, “10/11/2020”)
    The following substitution can be made:
    I see the text “The Budget Period end on: {SavedValue:BudgetPeriodEndDate}”

    I see the text “The Budget Period end on: 10/11/2020”

  3. Given that the following call will login a user with Username “qwe@qwe.com.qa2” , Password “test@1234”, and Email “qwe@qwe.com”:
    I login as “EXE FO” user
    The following substitutions can be made:
    I see the text “The Username: {Username:EXE FO}”
    I see the text “The Password: {Password: EXE FO}”
    I see the text “The Email: {Email:EXE FO}”

    I see the text “The Username: qwe@qwe.com.qa2”
    I see the text “The Password: test@1234”
    I see the text “The Email: qwe@qwe.com

  4. Given that the current date is “10/27/2020”, the following substitutions can be made.
    I see the text “Current Date (day first): {Date:dd/MM/yyyy}”
    I see the text “Current Date (month first): {Date:MM/dd/yyyy}”
    I see the text “Current Date (with time): {Date:dd/MM/yyyy hh:mm:ss}”
    I see the text “Last of the Month: {Date:dd/MM/yyyy::d=1;M+1;d-1}”

    I see the text “Current Date (day first): 27/10/2020”
    I see the text “Current Date (month first): 10/27/2020”
    I see the text “Current Date (with time): 27/10/2020 12:34:12”
    I see the text “Last of the Month: 10/31/20”

Misc

Setting Global Variable and Accessing it:

TestingBlazeGlobal.setValue(variableName,Value ); TestingBlazeGlobal.getValue(variableName);

Turn off element highlighting feature for specific element:

TestingBlazeGlobal.setVariable("highlightElements", "off");

Enabling wait for any Processing/In progress fading screen:

TestingBlazeGlobal.setVariable("processingHoldOnScreen",ByUsing.xpath("Xpath of nav page"));

Sample project

please refer to the Sample Project

Project Link: The Testing Blaze Automation Solution

Framework Libraries

All libraries can be simply accessed using I.amPerforming() in any java class.s

ActionsToGet: To get or fetch any information from a webpage

I.amPerforming().actionToGet().attribute(T locator, String attribute); I.amPerforming().actionToGet().attribute(T locator, String attribute, Boolean processing); I.amPerforming().actionToGet().text(T locator); I.amPerforming().actionToGet().text(T locator, Boolean processing); I.amPerforming().actionToGet().cssProperty(T locator, String property); I.amPerforming().actionToGet().cssProperty(T locator, String property, Boolean processing);

checkToSee: To verify.

I.amPerforming().checkToSee().isDisplayed(T locator); I.amPerforming().checkToSee().isDisplayed(T locator, Boolean processing); I.amPerforming().checkToSee().isEnabled(T locator); I.amPerforming().checkToSee().isEnabled(T locator, Boolean processing); I.amPerforming().checkToSee().isTableSorted(List rows_table, String sorting); I.amPerforming().checkToSee().isElementDisplayed(T locator); I.amPerforming().checkToSee().isElementDisplayed(T locator, Boolean processing); I.amPerforming().checkToSee().isElementPresentQuick(T locator); I.amPerforming().checkToSee().isInteractable(WebElement element); I.amPerforming().checkToSee().isSelected(T locator); I.amPerforming().checkToSee().isSelected(T locator, Boolean processing); I.amPerforming().checkToSee().isStale(WebElement element); I.amPerforming().checkToSee().popupPresent(); I.amPerforming().checkToSee().textPresent(String expectedText);

Click: Performs click on webpage , mobile etc.

I.amPerforming().click().on(T locator); I.amPerforming().click().on(T locator, Boolean processing); I.amPerforming().click().withJavaScript(T locator); I.amPerforming().click().withJavaScript(T locator, Boolean processing); I.amPerforming().click().withTapOnScreen(); I.amPerforming().click().withMouse().at(int x, int y); I.amPerforming().click().withMouse().on(T locator); I.amPerforming().click().withMouse().on(T locator, Boolean processing); I.amPerforming().click().withMouse().doubleClickOn(T locator); I.amPerforming().click().withMouse().doubleClickOn(T locator, Boolean processing); I.amPerforming().click().withMouse().dragAndDrop(T source, T target); I.amPerforming().click().withMouse().dragAndDrop(T source, T target, Boolean processing); I.amPerforming().click().withMouse().dragAndDropInHtml5(T source, T target); I.amPerforming().click().withMouse().dragAndDropInHtml5(T source, T target, Boolean processing); I.amPerforming().click().withMouse().onAndHold(T locator, int holdTimeSeconds); I.amPerforming().click().withMouse().onAndHold(T locator, int holdTimeSeconds, Boolean processing); I.amPerforming().click().withMouse().rightClickOn(T context); I.amPerforming().click().withMouse().rightClickOn(T context, Boolean processing);

browserOperationTo: Perform variouss browser related operations

I.amPerforming().browserOperationsTo().closeBrowserOrTab(); I.amPerforming().browserOperationsTo().getCurrentUrl(); I.amPerforming().browserOperationsTo().getPageLoadStatus(); I.amPerforming().browserOperationsTo().getJQueryStatus(); I.amPerforming().browserOperationsTo().getPageSource(); I.amPerforming().browserOperationsTo().getPageTitle(); I.amPerforming().browserOperationsTo().getPageXOffSet(); I.amPerforming().browserOperationsTo().getPageYOffSet(); I.amPerforming().browserOperationsTo().navigateBack(); I.amPerforming().browserOperationsTo().navigateForward(); I.amPerforming().browserOperationsTo().navigateToUrl(String url); I.amPerforming().browserOperationsTo().refreshPage();

comparisonOf:Compare images and tables etc.

I.amPerforming().comparisonOf().image().isElementImage(WebElement element, String imageName); I.amPerforming().comparisonOf().image().isElementImage(WebElement element, String imageName, Integer tolerance); I.amPerforming().comparisonOf().image().isFullName(String imageName); I.amPerforming().comparisonOf().image().isFullName(String imageName, int tolerance); I.amPerforming().comparisonOf().image().isImageSame(String image1withFullFilePath, String image2withFullPath); I.amPerforming().comparisonOf().image().isImageSame(String image1withFullFilePath, String image2withFullPath, int tolerance);

I.amPerforming().comparisonOf().sortAndCompareOneTableColumn(); I.amPerforming().comparisonOf().sortAndCompareWebTableWithTwoColumns(Map<Integer, List> twoColumnTable, String sortingOrder);

dateOperationToGet:-

I.amPerforming().dateOperationsToGet().currentDateInDesiredFormat(DateTimeFormatter formatter); I.amPerforming().dateOperationsToGet().currentDate(); I.amPerforming().dateOperationsToGet().currentDateWithOffsetInDesiredFormat(int offset, DateTimeFormatter formatter); I.amPerforming().dateOperationsToGet().givenDateWithOffsetFromGivenDate(String date, int offset, DateTimeFormatter formatter); I.amPerforming().dateOperationsToGet().currentDateWithOffset(int offset);

dropDownSelection:

I.amPerforming().dropDownSelection().from(T locator); I.amPerforming().dropDownSelection().from(T locator, Boolean processing);

propertiesFileOperationsTo:

I.amPerforming().propertiesFileOperationsTo().generateLogs(); I.amPerforming().propertiesFileOperationsTo().getValue(String key); I.amPerforming().propertiesFileOperationsTo().ReadPropertyFile(String fileName, String parameter); I.amPerforming().propertiesFileOperationsTo().getAllSavedKeys(); I.amPerforming().propertiesFileOperationsTo().getCompleteEntrySetFromPropertyFile(File filePath, String fileName); I.amPerforming().propertiesFileOperationsTo().getSavedValuesMap(); I.amPerforming().propertiesFileOperationsTo().loadCompleteEntrySetFromPropertiesFileToSaveValueMap(File filePath, String fileName); I.amPerforming().propertiesFileOperationsTo().setProperty(String key, String value);

emailOperationsTo:

I.amPerforming().emailOperationsTo().accessEmail(String username, String password, Emails.HostName server, Emails.MailClient mailClient, Emails.EmailFolder emailFolder);

fileHandling: Read write files

I.amPerforming().fileHandling().forAdobeReaderAnd(); I.amPerforming().fileHandling().forDocumentsAnd(); I.amPerforming().fileHandling().forExcelAnd(); I.amPerforming().fileHandling().forJsonAnd(); I.amPerforming().fileHandling().toCreateDirectory(String pathOfDirectoryName); I.amPerforming().fileHandling().toCreateFile(String pathWithFileName); I.amPerforming().fileHandling().toDeleteFile(String fileNameWithExtensionAndPath); I.amPerforming().fileHandling().toDownloadAnyFileUsingURL(String fileNameWithExtension); I.amPerforming().fileHandling().toGetCompleteFilesListOnLocalDirectory(String path); I.amPerforming().fileHandling().toReadAnyFile(String filePathWithFileName); I.amPerforming().fileHandling().toRenameDownloadedTmpFile(File file, String fileName, String toFileType); I.amPerforming().fileHandling().toRenameFileWithSpecificExtension(File filePath, String fileName, String fromFileType, String toFileType); I.amPerforming().fileHandling().toWriteInFile(String pathWithFileName, String dataToWrite);

addOnsTo:

I.amPerforming().addOnsTo().flashColor(WebElement element, String color, int blinkNumber); I.amPerforming().addOnsTo().getStringRandomNumber(); I.amPerforming().addOnsTo().convertImageFileToBufferedImage(File fileName); I.amPerforming().addOnsTo().getJvmVariable(StringSelection variableName); I.amPerforming().addOnsTo().getKeyBoard(); I.amPerforming().addOnsTo().getRandomNumber(); I.amPerforming().addOnsTo().getResources(String fileNameWithExtension); I.amPerforming().addOnsTo().getRandomNumberInRange(T minimum, T maximum); I.amPerforming().addOnsTo().roundDouble(double value); I.amPerforming().addOnsTo().setJvmVariable(StringSelection variableName, String variable); I.amPerforming().addOnsTo().uploadFile(T locator, String input);

cookies:

I.amPerforming().cookiesOperationsTo().addCookie(Cookie cookie); I.amPerforming().cookiesOperationsTo().deleteAllCookies(); I.amPerforming().cookiesOperationsTo().getAllCookies(); I.amPerforming().cookiesOperationsTo().getCookie(String name); I.amPerforming().cookiesOperationsTo().deleteCookie(String name);

conversionOf:

I.amPerforming().conversionOf().imageToBase64String(String filePathToRead, String imageType); I.amPerforming().conversionOf().imageToByteArray(String filePathToRead, String imageType); I.amPerforming().conversionOf().imageToByteArray(String filePathToRead, String imageType); I.amPerforming().conversionOf().listOfListsToMapOfMaps(List<List> tableToConvert); I.amPerforming().conversionOf().stringToBy(String byLocator);

getElementReference:

I.amPerforming().getElementReference().forListOfElements(); I.amPerforming().getElementReference().of(T locator); I.amPerforming().getElementReference().of(T locator, Boolean processing); I.amPerforming().getElementReference().ofNested(WebElement element, T locator);

mobileOperations:

I.amPerforming().mobileOperations().androidBatteryInfo(); I.amPerforming().mobileOperations().changeScreenOrientationToLandScape(); I.amPerforming().mobileOperations().changeScreenOrientationToPortrait(); I.amPerforming().mobileOperations().closeApp(); I.amPerforming().mobileOperations().getContextHandlers(); I.amPerforming().mobileOperations().getCurrentContext(); I.amPerforming().mobileOperations().getDeviceTime(); I.amPerforming().mobileOperations().androidBatteryInfo(); I.amPerforming().mobileOperations().getScreenOrientation(); I.amPerforming().mobileOperations().getScreenSource(); I.amPerforming().mobileOperations().hideKeyboard(); I.amPerforming().mobileOperations().installApp(String path); I.amPerforming().mobileOperations().isAppInstall(String bundleId); I.amPerforming().mobileOperations().openAndroidNotifications(); I.amPerforming().mobileOperations().openApp(); I.amPerforming().mobileOperations().runAppInBackGround(int seconds); I.amPerforming().mobileOperations().showKeyboard(); I.amPerforming().mobileOperations().switchContext(String context);

restHttp: For making API calls

I.amPerforming().restHttp().DeleteCall(JsonElement jsonElement, String stringBody, String endPoint, String key, String keyValue, String authToken); I.amPerforming().restHttp().getCall(String endPoint, String key, String keyValue); I.amPerforming().restHttp().patchCall(JsonElement jsonElement, String stringBody, String endPoint, String key, String keyValue, String authToken); I.amPerforming().restHttp().postCall(JsonElement jsonElement, String stringBody, String endPoint, String key, String keyValue, String authToken); I.amPerforming().restHttp().putCall(JsonElement jsonElement, String stringBody, String endPoint, String key, String keyValue, String authToken); I.amPerforming().restHttp().rawRequest(RestfulWebServices.CallTypes callTypes, RequestSpecification requestLoad, String endPoint);

sanityOfXpathTo: To make Xpaths very smart

I.amPerforming().sanityOfXpathTo().contains(String field, String value); I.amPerforming().sanityOfXpathTo().equals(String field, String value); I.amPerforming().sanityOfXpathTo().concat(String xpath1, String xpath2); I.amPerforming().sanityOfXpathTo().translate(String value);

robotActionsTo:

I.amPerforming().robotActionsTo().copy(); I.amPerforming().robotActionsTo().getRobot(); I.amPerforming().robotActionsTo().ctrl_Press(); I.amPerforming().robotActionsTo().ctrl_Release(); I.amPerforming().robotActionsTo().ctrl_Save(); I.amPerforming().robotActionsTo().enter(); I.amPerforming().robotActionsTo().escape(); I.amPerforming().robotActionsTo().mouseClick(int x, int y); I.amPerforming().robotActionsTo().enter();

scroll: Although framework auto scrolls but you still have scroll controls

I.amPerforming().scroll().onGadgets(); I.amPerforming().scroll().onPageDocument(String scrolltype, int xAxis, int Yaxis); I.amPerforming().scroll().onPageWindow(String scrolltype, int xAxis, int Yaxis); I.amPerforming().scroll().toMoveToElement(T locator); I.amPerforming().scroll().onPageToSpecificElement(T locator); I.amPerforming().scroll().toMoveToElement(T locator, Boolean processing); I.amPerforming().scroll().toDragAndDropByOffset(T locator, int xOffset, int yOffset, Boolean processing); I.amPerforming().scroll().toDragAndDropByOffset(T locator, int xOffset, int yOffset, Boolean processing); I.amPerforming().scroll().onPageDocument(String scrolltype, int xAxis, int Yaxis); I.amPerforming().scroll().onPageDocument(String scrolltype, int xAxis, int Yaxis); I.amPerforming().scroll().toElementCenter(T locator); I.amPerforming().scroll().toMoveSlider(T sliderLocator); I.amPerforming().scroll().toMoveSlider(T sliderLocator); I.amPerforming().scroll().toMoveSliderByOffset(T sliderLocator, int xOffset, int yOffset); I.amPerforming().scroll().toMoveSliderByOffset(T sliderLocator, int xOffset, int yOffset); I.amPerforming().scroll().toZoomInOut(int zoom); I.amPerforming().scroll().withKeyBoardToElement(T locatorScrollTo); I.amPerforming().scroll().withMouseToElement(T locatorScrollTo); I.amPerforming().scroll().withMouseToElementAndOffset(T locator, int xOffset, int yOffset);

snapshot:

I.amPerforming().snapShotTo().captureFullScreenShot(); I.amPerforming().snapShotTo().captureScreen(String fileName); I.amPerforming().snapShotTo().captureScreenshot(String screenshotName); I.amPerforming().snapShotTo().getlementScreenShot(WebElement element); I.amPerforming().snapShotTo().getScreenshot(); I.amPerforming().snapShotTo().takeElementScreenShot(WebElement element, String imageName);

switchTo: Although framework auto switches to iframes and switch back but you can control

I.amPerforming().switchTo().acceptAlert(); I.amPerforming().switchTo().frame(T locator); I.amPerforming().switchTo().getWindowsHandlers(); I.amPerforming().switchTo().activeContext(); I.amPerforming().switchTo().defaultContent(); I.amPerforming().switchTo().getAlertText(); I.amPerforming().switchTo().parentFrame(); I.amPerforming().switchTo().rejectAlert(); I.amPerforming().switchTo().windowHandler(int handlerNumber);

textInput:

I.amPerforming().textInput().in(T locator, String input); I.amPerforming().textInput().in(T locator, String input, Boolean processing); I.amPerforming().textInput().toClear(T locator); I.amPerforming().textInput().toClear(T locator, Boolean processing); I.amPerforming().textInput().withJavaScript(T locator, String input); I.amPerforming().textInput().withJavaScript(T locator, String input, Boolean processing);

updatingOfReportWith: Update report logs if needed

I.amPerforming().updatingOfReportWith().write(LogLevel logLevel, String reportLog); I.amPerforming().updatingOfReportWith().newLine(); I.amPerforming().updatingOfReportWith().write(LogLevel logLevel, ConsoleFormatter.ICON icon, String reportLog); I.amPerforming().updatingOfReportWith().write(LogLevel logLevel, ConsoleFormatter.COLOR color, ConsoleFormatter.ICON icon, String reportLog);

waitFor:Although framework has smart builtin wait strategy but you can control waits

I.amPerforming().waitFor().Alert(); I.amPerforming().waitFor().Alert(long customWaitTime); I.amPerforming().waitFor().AttributeToContain(By locator, String attribute, String value, long customWaitTime); I.amPerforming().waitFor().AttributeToContain(By locator, String attribute, String value); I.amPerforming().waitFor().AttributeToEqual(By locator, String attribute, String value, long customWaitTime); I.amPerforming().waitFor().AttributeToEqual(By locator, String attribute, String value); I.amPerforming().waitFor().disappearForProcessingONLY(By locator, long customWaitTime); I.amPerforming().waitFor().ElementListToBePresent(By locator); I.amPerforming().waitFor().ElementListToBePresent(By locator, long customWaitTime); I.amPerforming().waitFor().ElementToBeClickable(By locator, long customWaitTime); I.amPerforming().waitFor().ElementToBeClickable(By locator); I.amPerforming().waitFor().ElementToBePresent(By locator); I.amPerforming().waitFor().ElementToBePresent(By locator, long customWaitTime); I.amPerforming().waitFor().AttributeToEqual(By locator, String attribute, String value); I.amPerforming().waitFor().AttributeToEqual(By locator, String attribute, String value, long customWaitTime); I.amPerforming().waitFor().AttributeToContain(By locator, String attribute, String value, long customWaitTime); I.amPerforming().waitFor().AttributeToContain(By locator, String attribute, String value); I.amPerforming().waitFor().ElementToBeSelected(By locator); I.amPerforming().waitFor().ElementToBeSelected(By locator, long customWaitTime); I.amPerforming().waitFor().WebElementListToDisappear(List elements); I.amPerforming().waitFor().WebElementListToDisappear(List elements, long customWaitTime); I.amPerforming().waitFor().WebElementToBeClickable(WebElement element); I.amPerforming().waitFor().WebElementToBeClickable(WebElement element, long customWaitTime); I.amPerforming().waitFor().WebElementToBeSelected(WebElement element); I.amPerforming().waitFor().WebElementToBeSelected(WebElement element, long customWaitTime); I.amPerforming().waitFor().WebElementToBeVisible(WebElement element); I.amPerforming().waitFor().WebElementToBeVisible(WebElement element, long customWaitTime); I.amPerforming().waitFor().getCurrentTimeInSecs(); I.amPerforming().waitFor().getWaitTime(); I.amPerforming().waitFor().makeThreadSleep(int threadSleep); I.amPerforming().waitFor().TextToContain(By locator, String text); I.amPerforming().waitFor().TextToContain(By locator, String text, long customWaitTime);

Become a Contributor by Forking the project today.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages