Posts

Install Sauce Connect on Mac OSX and Run from local

   Install Sauce Connect on Mac OSX App name : Sauce Connect App description : sauce-connect (App: Not Available) App website :  https://docs.saucelabs.com/reference/sauce-connect/ Install the App Press  Command+Space  and type  Terminal  and press  enter/return  key. Run in Terminal app: ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null ; brew install caskroom/cask/brew-cask 2> /dev/null and press  enter/return  key.  If the screen prompts you to enter a password, please enter your Mac's user password to continue. When you type the password, it won't be displayed on screen, but the system would accept it. So just type your password and press ENTER/RETURN key. Then wait for the command to finish. Run: brew cask install sauce-connect In terminal set all the required parameter export SAUCELABS_HOST="127.0.0.1" export SAUCELABS_PORT="4448...

Handle custom tags using WebDriver

Sometime while doing automation we have to identify the element which have custom tags like <g> <svg> etc. For this we normally use * that will identify all elements tags in case we have to identify only specified custom tag then we can use below example for this. < svg height = "600" width = "910" xmlns : xlink = "http://www.w3.org/1999/xlink" id = "svgcontent" overflow = "visible" x = "910" y = "600" viewBox = "0 0 910 600" > < g style = "pointer-events:all" > < text fill = "rgb(0,0,0)" font - family = "Sans-Serif" font - size = "13" id = "80-155-126" transform = "rotate(-90, 168, 126)" y = "126" x = "168" style = " pointer - events : inherit "> A100A </ text > </ g > </ svg > Following Xpath will work here ...

EXTRACT CSS PROPERTY VLAUE OF PSEUDO ELEMENTS CONTAINING :after/:before CSS TAG USING JAVASCRIPT IN WEBDRIVER :

Image
We cannot extract css properties of pseudo elements using web driver commands such as ‘.getPropertyValue’ . For this, we need to use JavaScript and execute a js script in selenium web driver. A CSS pseudo-element is used to style specified parts of an element.    For example, it can be used to:    Style the first letter, or line, of an element    Insert content before, or after, the content of an element ISSUE: In above scenario, we need to get the text “Internal Use Only” from UI which is associated with an Anchor (a) tag in DOM with :after CSS tag. The text is present in “content” Style Property as shown in right highlighted box. The :after CSS tag cannot be located directly using web driver and thus required text cannot be retrieved simply by using .getPropertyValue() function in selenium. To achieve this, a javascript needs to be executed in our selenium code : WebElement elementObj = driver . findElement ( By . xpath...

Useful Tips in Mobile Automation

  How to use ADB (Android Debug Bridge) over wifi | ...   How to know app package and activities information... Webdriver compare data/css between two pages How to Re-Sign an ios App from an External Develop... To know all devices connected to machines / simula... Automation Testing of Android app on device using ... Calabash ios installation steps Calabash-ios commands INSTALL IDEVICEINSTALLER ON MAC MACHINE MOBILE WEB/APPLICATION AUTOMATION INSTALLATION GUI... Easiest Way to Get the Crash Logs in ios   Blocking Internet for Specific Apps Business Models: How Does Mobile App Makes Money?   Projecting Android Screen on to Your PC Bandwidth Throttling Using Fiddler   ADB commands with examples Android Screencast: Android screen to Windows PC Limiting Internet Speed On Your Mobile Device (Ban...     Wireless ADB   Recording Android Device Screen using ADB   Securing Your Smartphones   Mobile Application Testing –...

Actual differences between Explicit and Implicit Waits

Hi All, As i have already mentioned the differences Explicit and Implicit Waits in my earlier post but now we will see the actual results. there will be two conditions we can think of it what will happen if implicit wait is greater than explicit wait OR  implicit wait is lower than explicit wait lets see what will happen Condition 1: implicit wait is greater than explicit wait            implicitlyWait = 10 seconds             explicitWait = 2 seconds             ///////////////////////////////////////             public static void main(String[]args) {             FirefoxDriver driver = new FirefoxDriver();             driver.manage...

WebDriver | Automation | launch/Execute on different version of Firefox

Image
Run tests on specific Firefox version | Selenium Firefox binary Imagine a situation where you have to test your web application against two different versions of the Firefox browser. By default, when you instantiate FirefoxDriver, the Firefox version that is available on the PATH variable is launched. But if you want to launch a different version of Firefox, we need to use Firefox Binary. For this first steps you have to install all the versions of Firefox which you want to test on your system. Make sure the installed Firefox versions on different path locations using Custom installation Installing multiple versions of Firefox Suppose you have already installed the Firefox( version 22 ) means default Firefox is already installed. this can be found on your program file location like this.. "C:\Program Files (x86)\Mozilla Firefox" Now we have to install another Firefox version (lets take Firefox version 23 ). 1. Download this version from Mozilla s...