Forum Discussion
tristaanogre
7 years agoEsteemed Contributor
We have something similar... it's a panel (DIV) in the HTML that is made visible when such a thing happens. We wrote a little bit of code to check to see if the panel is visible and, if it is, wait for it to go away.
function waitForLoading(timeout) { var loadingForm; var counter = 0; if ((timeout == undefined) || (timeout == null)) { timeout = 60; } Aliases.browser.panelLoading.RefreshMappingInfo(); Aliases.browser.panelLoading.WaitProperty('Visible', true, 5000); while ((Aliases.browser.panelLoading.Visible) && (counter < (timeout * 2))){ aqUtils.Delay(500, 'Waiting for loading panel to close'); counter++ } }
Obviously, the object itself is going to be different for you than for us so your Aliasing/Mapping would be different.... but this is what we do...
Generally speaking, you as the tester know when these such things should come up so you can add this detection code in to wait for it when you know it's expected.
Related Content
- 3 years agobutoy07
- 3 years agoAlefi1
- 11 years agokevinkleint