Dialog's Handle() method

4 posts, 0 answers
  1. Adam
    Adam avatar
    2 posts
    Member since:
    May 2011

    Posted 11 May 2011 Link to this post

    Does anyone know what actions are taken within the Dialog's Handle() method, everywhere I have looked it just says, "Handle this dialog." or something along those lines. The main reason I ask is because it seems to me like the popup is being handled by highlighting the desired button then pushing enter.
    If this is the case is there any way to override that to use the mouse? Often times we run our full regression suite over the weekend and if any popups occur the test will timeout, and not move on until something is clicked, because there it does not have keyboard control.

    Please let me know if you have any input, suggestions, or questions.


    Thanks,

    -Adam
  2. Stoich
    Admin
    Stoich avatar
    1 posts

    Posted 17 May 2011 Link to this post

    Hello Adam,
        how do you run your regression suite? In what state are the machines it runs on (locked/unlocked, sleeping etc.)?

    You're probably running into a common test automation challenge. Windows chooses not to render some elements of its GUI when it deems no one is looking (i.e. when the machine is sleeping for instance). This can cause failure in certain types of steps. This issue exists for all types of test automation software not only Test Studio. Depending on how you run your regression suit this might be the problem.

    My other suggestion is to check out the UnexpecedDialogAction mode in your TestList settings as seen in this KB article:
    http://www.telerik.com/automated-testing-tools/support/kb/avoiding-dialog-handling-problems-with-the-unexpecteddialogaction-feature.aspx

    Greetings,
    Stoich
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>

  3. Adam
    Adam avatar
    2 posts
    Member since:
    May 2011

    Posted 17 May 2011 Link to this post

    Hello Stoich,

    Usually we run the suite over the weekend with the computer locked. I set
    settings.UnexpectedDialogAction = UnexpectedDialogAction.DoNotHandle;
    because when we run we want to know what popups are appearing and we want to handle them.

    Is there any way to enable full viewing when the box is locked or any suggestions you have to make it properly handle the popup. It seems even when we run the tests with the box unlocked and fully functional that it still doesn't click the desired button in the dialog box, it highlights the desired button and then pushes enter, I tested this by watching the test until it got close to the portion where the popup appears then continued to click off the browser into another window where it pushed the enter key and moved my text around.

    Thank you,
    -Adam
  4. Stoich
    Admin
    Stoich avatar
    1 posts

    Posted 20 May 2011 Link to this post

    Hi Adam,
        I would like to reproduce this issue. Could you please look around on the Internet for a Dialog sample that exhibits this behavior. Also, please send me the code you use to handle the Dialog. Alternatively, you can put together the sample yourself.

    All the best,
    Stoich
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>

Back to Top
  Cast Your Vote at DevPro Connections! Cast Your Vote at  Win IT Pro Connections!