Clicking on a HTML dropdown list doesn't drop the list

2 posts, 0 answers
  1. hasantha
    hasantha avatar
    9 posts
    Member since:
    Jun 2014

    Posted 17 Jun 2014 Link to this post

    We have hybrid android mobile application. In a certain UI(html file) in the application, there's a drop-down menu which needs to be clicked(automated) using a test script. I tried using  web.tap() and, but the drop-down list didn't drop as it should do. I couldn't find any other methods specifically made to perform an click operation/event on a dropdown list in this page(Web API) . How do you achieve this?
  2. Shtilianov
    Shtilianov avatar
    7 posts

    Posted 20 Jun 2014 Link to this post

    Hi hasantha,

    Thank you for bringing this issue to us.

    Can you try if the following will work on your side:

    setSelectedValue should open the dropdown and select the item from the dropdown by its name as a string.
    // the dropdown element
    var dropdown = { 'id' : 'dropdown' };
    web.setSelectedValue(dropdown, "value"),
    // now for the verification, getSelectedValue should return the selected item as a string which can be asserted
    web.getSelectedValue(dropdown, function(res){

    I hope it helps.

    Test your Android and iOS apps against any device or browser with Telerik Mobile Testing. Part of the Telerik Platform.
Back to Top