Forum Discussion
I have the following in a test case that I have and it's working fine. This is a "Call Object Method" operation on a keyword test where the object is the indicator object.
As I watch my tests, I see the indicator getting hidden at this point so I do know that this works.
So... since it's working for me on a Windows 2012 Server box, a Windows 10 machine, and a Windows 7 machine, the question then is what is unique about your situation that is causing this not to work? Can you provide information like what kind of application you're testing, operating system, script language on your project, etc?
A screenshot, perhaps, of where you are implementing this method call would be useful, too.
Hi Robert,
Thanks for your reply. It's interesting to know that it works for you. I wonder what the difference is..
We are testing a desktop application written in Delphi. We use a physical Windows 10 Pro PC for our test environments. The project scripting language is DelphiScript.
Based on what I'd read I used the Call Object Method and the Code Snippet (one disabled, one enabled, not both running at the same time!) at the very beginning of the Keyword Test. My colleague used it just before he needs the window to close in the test.
See attached for screenshot of where and how it is implemented in the test.
It might be worth adding that we used to see an issue where the Indicator would disappear for some time, especially after a few hours of usage (in the afternoon for example). This makes us wonder if something has been changed in the Indicator in this Release that makes it more prominent? Just a thought..
Thanks,
Jenny
- tristaanogre7 years agoEsteemed Contributor
The question is: Where is that code in relation to when you need it to execute? The way we use it is that, when we know, in our automation, that we need to interact with something in the upper right of the screen, we call Indicator.Hide. Then, when we are done, we call Indicator.Show. My suspicion is that you may think that code is being called... but perhaps it is not being called when you think it should be. You can try dropping a breakpoint on the Indicator.Hide call and see if that is actually getting hit in your execution.
Now, you mentioned something... you need to hide the indicator so you can close a window. Any reason why you can't just called object.Close()? That seems to be the better solution... true, it doesn't answer the question about Indicator.Hide.... I'm going to fire up a quick DelphiScript project and see if that makes a difference but, as mentioned, I'm not expecting there to be a problem but I'll take a look.
- JennyH117 years agoFrequent Contributor
Hi Robert
The Indicator.Hide is much earlier in the test than the close window action. Actually, when I tried it yesterday it actually worked! But it stopped working after a few runs of that test. I've tried it today and it's failed again.
Thanks for the information about the object.Close method. We did try this beforehand and it worked fine. We would just prefer to use the Indicator.Hide and Indicator.Show methods because in the test we want to close the windows using the mouse action, as a user would.
It looks like the object.Close method is the one to go with for now but it would be better if the Indicator would Hide.
Thanks for your help!
Jenny
- tristaanogre7 years agoEsteemed Contributor
FYI, I just ran into this problem in our environment. I'll be creating a support case for it.
Related Content
Recent Discussions
- 2 days agoGane195