Forum Discussion
Hi,
Miscellaneous Category contains Delay operaton. Does it help?
- Marsha_R5 years agoModerator
You can add a Delay for some fixed length of time this way:
https://support.smartbear.com/testcomplete/docs/keyword-testing/reference/misc/delay.html
If you were running this test manually, how would you know if the internal process had stopped or not?
- tristaanogre5 years agoEsteemed Contributor
While you can add a physical delay, I'd still aim towards finding something more dynamic.
So, this internal process. What does it do? Does it update an SQL table? Create a file? etc? As Marsha_R suggested, if you were doing this manually, how would you know the internal process is complete? Would you click on something, check a value, and then wait and repeat the process?
The reason why I'd not do a physical delay is two-fold:
1) The process may take LESS time on some iterations through the test than you have the delay set for which would mean that you would have an automation process sitting doing nothing for a time when it could be continuing the process.
2) The process may take MORE time on some iterations through the test than you have the delay set for which would mean that you could end up with an invalid test because you didn't wait long enough.
So, finding a dynamic way to check the process and determine if it's complete will minimize the idle time of your process while allowing for long potential delays by setting a maximum timeout.
- Logiv5 years agoContributor
Hello Robert,
I understand what you are saying and I wanted to avoid "empty" delays, I know they are not the best.
In this case, nothing changes in SQL. Nothing changes on screen either. No variable is populated. I am testing a Point Of Sale software and after a sale, we revert back to the "initial" menu (if it was changed). In my case, the menu/screen was not changing in this specific test.
I need to test the transaction total after I hit the Cashout button, but since the process is trying to set back the menus to default, when I check the total immediatly it is empty. And the total is not shown as a field, we "draw" it on a generic form, there is only one object name and it doesn't change once the total is populated.
I don't know if I explained it well, but I do understand your statement! We might rewrite parts of our application to be more Automation-friendly over time, because as it is right now, it is not always easy. We have forms that use a dynamic number, each time the software is launched, it'll receive a different form number - it was not hardcoded when it was build. So it is hard for me to even verify if an object is active.Thanks for the help!
- Logiv5 years agoContributor
Hello Marsha,
We cannot run into this problem manually, or at least I was not able to. The process takes 65 milliseconds.
Well, in fact if I do transactions really fast, I can sort of hit the issue but it is hidden since I am not asking to get the total of the last transaction. The functions are "queued" and executed when the software is free. I am not too sure if I could test this within TestComplete.
I am not a programmer, nor do I have access to the source code, so my means are somehow limitted right now :(
Thanks for the insight.
- Logiv5 years agoContributor
Thank you Alex, it worked great. I just started using TestComplete and I am learning :)
Related Content
Recent Discussions
- 4 days ago
- 4 days ago