RE: How to validate?



I was trying to select few products and adding them to cart/Bag and I want to verify the selected Products are same in the cart/Bag. Please let me know how to do it.

URL is:

Note: What all items you are selecting those items should be in your shopping cart.

Rocky Doctor Asked on September 6, 2014 in Selenium WebDriver.
Add Comment
5 Answers

Virender I am working on MDF and I am pasting screenshot may you can understand (Hopefully).

Function is below:

public static WebElement productCategory_Accessories(WebDriver driver){

WebElement element = driver.findElement(By.linkText("Product Category"));

Actions action = new Actions(driver);


WebElement subElement = driver.findElement(By.linkText("Accessories"));



return element;


Called above function:

1st step: Selected the items

RE: How to validate?

2nd Step: In the cart page, selected items are displayed and verify the Selected items are same as above (Step no 1). How to do this? 

RE: How to validate?

Hope all is well 🙂

Doctor Answered on September 6, 2014.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.