Ask a Question

Dropdown selection not changing

SOLVED
kate123
New Contributor

Dropdown selection not changing

When my test case involves making a selection from a dropdown window, I get the following error message - " The combo box item 'XXX' was clicked, but the selection was not changed. "  Is there a way to fix this?

8 REPLIES 8
tristaanogre
Esteemed Contributor

I'm curious as to how you have your code written.  Typically a "ClickItem" should do it.  However, depending upon the application (especially if it's a web application) there may be code behind the scenes that needs to finish before all components are ready for interaction so ClickItem could execute but a final step in the page load could wipe it out.

 

Could you share some more information?  What type of application are you testing? What type of component is it? Could you copy paste the code here or screenshot the keyword test?

 


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

Hello Robert,

This is a web application and I am trying to enter the hotel rating from a dropdown list.  I attached a screenshot of the Keyword test.


Thanks.

 

Kate

tristaanogre
Esteemed Contributor

Rough guess.... but each time you change values in that filter, specifically the distance, are there some other things taht change on the page?  Do new fields display or other such stuff?

 

Just as a test (I'm not suggesting keeping it permanently there), what happens if you drop like a 2 second delay after the "SetText 10"?


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

No other change on the page and no new fields.  I tried adding the delay and that didn't work either. =(

I am finding that most of my test cases are failing due to this same issue.  Argh.

tristaanogre
Esteemed Contributor

OK... going out on a limb.  I see that this application seems to be a listing of multiple hotels, each one that you're editing.  I'm wondering if there is something going on confusing the object recognition... where you're calling ClickItem on one but that there may be another non-visible component that is being recognized as well.  

What's your mapping look like for the drop down?  If, in NameMapping, you right click on the item and select "Show in Object Browser" or "Highlight on Screen", does the correct component highlight?


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
TanyaYatskovska
SmartBear Alumni (Retired)

Thanks for the assistance, Robert!

 

@kate123, did the suggestions given in this thread help you?

---------
Tanya Yatskovskaya
SmartBear Community and Education Manager



Hi Robert,

I don't know what's going on but my test cases are running again without failing.  This is so strange since I didn't make any changes to them.  So bizzare.  Thank you for all your help though.  😃

 

Kate

TanyaYatskovska
SmartBear Alumni (Retired)

Hi Kate,

It's a miracle 🙂

Sometimes they happen! Happy to hear that everything is ok now.

---------
Tanya Yatskovskaya
SmartBear Community and Education Manager



cancel
Showing results for 
Search instead for 
Did you mean: