security certificate - there must be a better way

3 posts, 1 answers
  1. Asare
    Asare avatar
    17 posts
    Member since:
    Sep 2012

    Posted 11 Oct 2012 Link to this post

    Test Studio does not allow you to test for a non existent DOM

    Which makes testing for security certificate page  difficult.

    My approach is to use a logical condition (if...else)



    However, this only works when the page is displayed. If the page is not displayed essentially the step fails regardless what ever the else statement says.

    To get around the failing else I use the "Continue on Failure "

    There must be a better way. I have looked at coding but the same issue persists.

    Any suggestions?
  2. Answer
    Mario
    Admin
    Mario avatar
    8 posts

    Posted 11 Oct 2012 Link to this post

    Hello Asare,

    Thank you for contacting Telerik Support.

    If you would benefit from avoiding this certificate message altogether, please see how to register a security certificate with TestStudio from our online documentation.

    As far as your logical condition, I believe your issue stems from the Verify condition itself. Currently you are comparing 'TextContent' to contains the expected text. If the security certificate page pops up then 'TextContent' will exist and be compared to contain the text and hence your step will pass. However if you do not come to the security certificate at this point 'TextContent' will not exist at all and your Verify will fail the step as it cannot find the element to compare its content. If you were to change the Verify in your logical IF to check Verify  'TextContent'  Exists (or another element) then it would properly go to your ELSE statement when it does not see the item. If you wish you could Verify 'TextContent' Contains after determining it exists at all. 

    Let me know whether this solution works for you.

    Greetings,
    Mario
    the Telerik team
    Are you enjoying Test Studio? We’d appreciate your vote in the ATI automation awards.
    Vote now
  3. Asare
    Asare avatar
    17 posts
    Member since:
    Sep 2012

    Posted 16 Oct 2012 Link to this post

    I have tested it using Wait for ..
Back to Top