Posts

Showing posts with the label Custom firefox profile

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 ...

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...

Selenium disable add-ons pop-up for Custom firefox profile

Here is the way to disable add-ons window which appears every time when selenium scripts are run on Custom Firefox Profile. Close all instances of Firefox browser and delete the following files from the Custom Profile folder, this should reset Extension Manager and disable add-ons pop-up: extensions.cache extensions.ini extensions.rdf compatibility.ini This Add-ons pop-up will not displayed the next time you run selenium scripts. To find the Firefox profile,  type in cmd run prompt "%APPDATA%\Mozilla\Firefox\Profiles\"  press enter