Write and validate XPath Expressions and CSS Selectors in Chrome and Firefox browser

Hello Folks, We have learnt different ways of writing XPath expressions and CSS Selectors. There are some tools which generate XPath and CSS automatically for use. But for better understanding of concepts, you must write these by your own. So, in this post we will learn : How to write and validate XPath Expressions and CSS … Continue reading Write and validate XPath Expressions and CSS Selectors in Chrome and Firefox browser

CSS Selector In Selenium Webdriver: Points You Must Know

Hello Folks, We have seen all locators except CSS Selectors in old posts. You can find links of old posts below: ID Locator name, className, linkText, PartialLinkText, tagName Locators Xpath Basic concepts Xpath Advanced Concepts We will cover CSS Selector in this post. We will see below topics: What is CSS?What is CSS Selectors?Different ways … Continue reading CSS Selector In Selenium Webdriver: Points You Must Know

All about findElement() and findElements() methods

Hello Folks, In this post we will learn: What is findElement() method. What is findElements() method. What is difference between findElement() and findElements() methods. What is common between findElement() and findElements() methods. Exception thrown in case of element is not found. Introduction: A webpage has many elements like button, text box etc. These elements are called … Continue reading All about findElement() and findElements() methods

Independent-dependent concept in XPath Expression

Hello Folks, I will explain independent-dependent concept in writing XPath expression. Consider below scenario: You need to get the displayed price of iPhone 7 of all variants on Flipkart website. As we know price will vary based on model number, memory, color etc. Even price may change also with time or when some sale in … Continue reading Independent-dependent concept in XPath Expression

Part 2: All about XPath: Different ways of writing XPath expression.

Hello Folks, In last post we have learnt basic concepts about XPath. In this post ,we will learn to write XPath expressions: Using attribute name and value Using contains method Using ‘and’ operator Using ‘or’ operator Using last() method Using starts-with method Using wildcard character (*) Using text() method Using position method Using attribute name … Continue reading Part 2: All about XPath: Different ways of writing XPath expression.

Part 1: All about XPath in Selenium Webdriver: Basic concepts

Hello Folks, We have learnt 6 locators till now in details(Part 1 and Part 2). In this post we will learn: What is XPath. Absolute XPath Relative XPath Difference between single slash and double slash. Understating the term immediate nodes, Any nodes and indexed nodes. XPath is one of the locators available in selenium Webdriver. … Continue reading Part 1: All about XPath in Selenium Webdriver: Basic concepts

Part 2: Ways of locating Web element using: Name, Class Name, Tag Name, Link Text

Hello Folks, In last post , I explained about locating web element using ID. I explained last post in details so that you will be able to understand other locators easily. We will learn in this post: Locating web element using name. Locating web element using tag name. Locating web element using link text. Locating … Continue reading Part 2: Ways of locating Web element using: Name, Class Name, Tag Name, Link Text