Forum Discussion
What it sounds like is that, generally speaking, you're dealing with timing issues with your tests. It takes JUST a little bit too long for an object to be available for interaction, or visible on screen, or to be refreshed after making a change... and the tests fail.
Running them individually, you have less processes running, most likely, and the system responds better. Just off the top of my head, I'm thinking you will need to increased your auto-wait timeout, either globally on the project or in specific "Wait" calls you are making.
It may help us help you more if you can give us screenshots of the logs that demonstrate these particular problems. We may be able to target a solution better.
- ameykhopade8 years agoContributor
Hi
Yes i too had the same doubt regarding the timing issue and for that I tried to add a exist check.
While Not object.VisibleOnScreen'or object.Exists aqUtils.Delay 1000 ' 1 sec delay If counter > 60 then Break() Else counter = counter + 1 End If WEnd
But here the Break statement is not working and o the infinite loop as I need to time out the test if the object is not available after some time.
Not sure What i am missing here.
And what exactly do you need from the testlog should i share the error message or any other thing from the log
thanks,
amey
- tristaanogre8 years agoEsteemed Contributor
Instead of just calling the Exists or VisibleOnScreen property, simply use WaitChild or WaitAliasChild with a timeout delay set to 60 seconds. Something more like this (sorry, I don't know VB syntax very well so I'm doing it in Java)
if (!parentobject.WaitAliasChild('myObject', 60000).Exists) { Log.Error('Object did not appear within 60 seconds); }
As for the test log, it would be good to know
1) What the actual text is of the error message you're getting
2) Information from the "Additional Info" panel for the error message
3) Some sample of the code that is generating the error message.
These will help to debug the problem. As mentioned, it is most likely a timing issue.
Something you can do, more globally, is in Tools | Current Project Properties | Playback, increase your auto-wait timeout. The default is typically 10 seconds. Bump that up to 20 or 30 seconds to see if this corrects the problem.- ameykhopade8 years agoContributor
I already tried this
If not sys.WaitChild(myobject,100000).Exists then end if
But this isnt working either.
I am using waithchild method on sys object and myobject contais the Full name of the object.
I have attached the error snaps for.
1. Errormessage_1.PNG
this the error message i am getting of the objects. this objects are available on the screen but the click action is not performed on this.
2.AdditionalInfo_1.PNG
this code line generates the error
Execute(strCommandLine)
here strCommandLine is a string variable which contains the :
"Call Sys.Browser("iexplore").Page("*").Form("aspnetForm").Panel("divHeaderAndContentPanel").Panel("divHeaderAndContent").Panel("divHeaderContainer").Panel("divHeader").Table(0).Cell(0, 1).TextNode("cphActionsRight_cmdManage").Click"
in the frame work I am using all the action are preformed using the "execute" method.
In Image.PNG contains the image of the button on which the action is to be performed.
"There was an attempt to perform an action on a zero-sized window" this the error message i am getting mostly where the object is present and available on screen and the same tests when executed individually passes successfully.
Not able to figure out y this is happening
thanks,
Amey