Reporting Errors
Question ID: 104118
1
0

Here’s the scenario:

I’m navigating a website and click a link to move to the next page. The link has the option of sending me to 1 of 2 sites. One of the sites is an error site that appears randomly. I scripted an If statement saying that If the error site exists then reporter.reportevent the website error occured. It then clicks a continue link to go back to a main page. If the error site does not occur, then I reporter.reportevent that the error did not occur.

Here’s the issue:
Every single time, regardless of whether the error occurs or not, the report comes back saying that the error occured. Why is this occuring and how can i fix it? Any feed back is appreciated!

Marked as spam
Posted by (Questions: 2, Answers: 3)
Asked on May 13, 2010 8:58 pm
45 views
Answers (2)
2
Private answer

When dealing with an error that appears randomly you will have better luck using QTP's Recovery Scenario Manager. With this tool, You can handle your error whenever it appears and write reports accordingly.

As a side note: You will have to right a small function to write to the reporter. You will call this function with the Recovery Scenario Manager

Marked as spam
Posted by (Questions: 2, Answers: 1)
Answered on May 14, 2010 2:02 pm
0
This is what i should have done. I don't have alot of experience with it though, which is why it didn't occur to me.
( at May 14, 2010 3:35 pm)
1
Private answer

What are you checking to see if the error site occurs? Depending on the technology that you are dealing with, you may have objects that are PRESENT but are not VISIBLE and therefore if you are checking for the existance of an object, QTP will find it, even if it is not VISIBLE, and may be giving you a false positive on the error page. Sometimes you need to add a property check for Visible = true as well was if it exists.

If you think it will help us understand, paste your check and reporter code so we can review it.

I hope this helps!

Marked as spam
Posted by (Questions: 17, Answers: 807)
Answered on May 14, 2010 2:34 pm
0
We actually modified the code to use child objects to locate the object we had and it would not locate the object on the page, even though it was visible right in the middle of the page.
( at May 14, 2010 3:01 pm)
EyeOnTesting

Welcome back to "EyeOnTesting" brought to you by Orasi Software, Inc.

X
Scroll to Top