Flipkart Price filter dropdown issue | Selenium Forum
M
Posted on 04/10/2016
Hi Ashish/Team,

I am trying to implement the Hybrid Framework for Flipkart (Module 21). I am facing an issue when filtering mobiles based on Min and Max values.

I was successfully able to select the Min value. But when i use the same sendKeys for the Max price filtering, i am not able to select the filter value.
So, i used the "/option[text()='maxPrice']" in xpath to select the value. I am able to select the value and the filtering is also applied. But the value in Max dropdown is still the default value and not the selected value.

I have tried with select class as well and the same issue is observed.

Attached is the function, ProductSuite.xlsx, project.properties. Rest of the things are as per the framework explained in Videos.

Could you please let me know how can i ensure that the dropdown value also gets updated?
Also, can you please help me to understand why is sendKeys not working for the Max filter after selecting Min filter?

Below is the screenshot:
[attachment=3:wqynw60m]Flipkart dropdown Max price.jpg[/attachment:wqynw60m]

M
Replied on 05/10/2016

contact me on skype qtpselenium1


M
Replied on 05/10/2016

Hi Ashish,

I have resolved the issue without requiring any wait time.
I have noticed that after selecting the Min price (manually), the Filters section is getting updated with MinPrice-35000+. But it is not happening when i am using sendKeys.

So, I have used the same code of selecting MaxPrice (i.e. clicking on the required value instead of using sendKeys)

Complete code as below for Price filter selection:

driver.findElement(By.xpath(prop.getProperty("minDropdown_xpath")+"/option[text()='"+priceMin+"']")).click();
driver.findElement(By.xpath(prop.getProperty("maxDropdown_xpath")+"/option[text()='"+priceMax+"']")).click();

Thank you for your feedback.