Class WebActionManager


  • public class WebActionManager
    extends ActionManager
    This class represents the things in common between Web projects
    • Constructor Detail

      • WebActionManager

        public WebActionManager()
    • Method Detail

      • click

        public static void click​(java.lang.String locatorElement,
                                 java.lang.String... locatorReplacementValue)
      • click

        public static void click​(java.lang.String locatorElement,
                                 java.lang.Boolean scroll,
                                 java.lang.String... locatorReplacementValue)
      • click

        protected static void click​(org.openqa.selenium.WebElement element)
      • click

        protected static void click​(org.openqa.selenium.WebElement element,
                                    java.lang.Boolean scroll)
      • maximizeWindow

        public static void maximizeWindow()
      • navigateTo

        public static void navigateTo​(java.lang.String url)
        Method is used to navigated to certain page
        Parameters:
        url - to go. Example: https://crowdar.com.ar
      • switchToLastTab

        public static void switchToLastTab()
        switch to the last tab
      • waitTabOpening

        public static void waitTabOpening()
                                   throws java.lang.InterruptedException
        Wait to appear more than one tab
        Throws:
        java.lang.InterruptedException
      • setDropdownByText

        protected static void setDropdownByText​(org.openqa.selenium.WebElement element,
                                                java.lang.String text)
      • setDropdownByText

        public static void setDropdownByText​(java.lang.String locatorElement,
                                             java.lang.String text,
                                             java.lang.String... locatorReplacementValue)
      • setDropdownByValue

        public static void setDropdownByValue​(java.lang.String locatorElement,
                                              java.lang.String text,
                                              java.lang.String... locatorReplacementValue)
      • setDropdownByValue

        protected static void setDropdownByValue​(org.openqa.selenium.WebElement element,
                                                 java.lang.String value)
      • setDropdownByVisibleText

        public static void setDropdownByVisibleText​(java.lang.String locatorElement,
                                                    java.lang.String text,
                                                    java.lang.String... locatorReplacementValue)
      • setDropdownByVisibleText

        protected static void setDropdownByVisibleText​(org.openqa.selenium.WebElement element,
                                                       java.lang.String value)
      • setDropdownByIndex

        public static void setDropdownByIndex​(java.lang.String locatorElement,
                                              java.lang.Integer index,
                                              java.lang.String... locatorReplacementValue)
      • setDropdownByIndex

        protected static void setDropdownByIndex​(org.openqa.selenium.WebElement element,
                                                 java.lang.Integer index)
      • getDropdownSelectedOption

        public static org.openqa.selenium.WebElement getDropdownSelectedOption​(java.lang.String locatorElement,
                                                                               java.lang.String... locatorReplacementValue)
      • getDropdownSelectedOption

        protected static org.openqa.selenium.WebElement getDropdownSelectedOption​(org.openqa.selenium.WebElement element)
      • getDropdownAllSelectedOptions

        public static java.util.List<org.openqa.selenium.WebElement> getDropdownAllSelectedOptions​(java.lang.String locatorElement,
                                                                                                   java.lang.String... locatorReplacementValue)
      • getDropdownAllSelectedOptions

        protected static java.util.List<org.openqa.selenium.WebElement> getDropdownAllSelectedOptions​(org.openqa.selenium.WebElement element)
      • deselectDropdownAll

        protected static void deselectDropdownAll​(org.openqa.selenium.WebElement element)
      • deselectDropdownAll

        public static void deselectDropdownAll​(java.lang.String locatorElement,
                                               java.lang.String... locatorReplacementValue)
      • deselectDropdownByValue

        protected static void deselectDropdownByValue​(org.openqa.selenium.WebElement element,
                                                      java.lang.String value)
      • deselectDropdownByValue

        public static void deselectDropdownByValue​(java.lang.String locatorElement,
                                                   java.lang.String value,
                                                   java.lang.String... locatorReplacementValue)
      • deselectDropdownByText

        protected static void deselectDropdownByText​(org.openqa.selenium.WebElement element,
                                                     java.lang.String text)
      • deselectDropdownByText

        public static void deselectDropdownByText​(java.lang.String locatorElement,
                                                  java.lang.String value,
                                                  java.lang.String... locatorReplacementValue)
      • deselectDropdownByIndex

        protected static void deselectDropdownByIndex​(org.openqa.selenium.WebElement element,
                                                      int index)
      • deselectDropdownByIndex

        public static void deselectDropdownByIndex​(java.lang.String locatorElement,
                                                   int index,
                                                   java.lang.String... locatorReplacementValue)
      • dragAndDrop

        protected static void dragAndDrop​(org.openqa.selenium.WebElement elementToDrag,
                                          org.openqa.selenium.WebElement elementToReplace)
        Method that drag and drop some element over other element
        Parameters:
        elementToDrag -
        elementToReplace -
      • dragAndDrop

        public static void dragAndDrop​(java.lang.String locatorToDrag,
                                       java.lang.String locatorToReplace)