Cannot get VCLObject on slave machine
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Cannot get VCLObject on slave machine
I have my automated testing envioronment configured as below:
Master: Windows 7 Enterprise, TestComplete 11.31.2420.7(floating) and TestExecute 11.31.2420.11. Has access to license server and the automated test LAN.
Slave: Windows 7 Ultimate, TestExecute 11.31.2420.11. Has access to only automated test LAN.
My to be tested software is developed with Delphi 2007. I have two ".exe" to test, A.exe(Aliases.A) and B.exe(Aliases.B), in the same project. I use python scripts.
On my master machine, everything works fine for both instances of Aliases.A and B(using TestComplete or TestExecute). I can properly detect the objects with either namemapping or with .VCLObject() method.
Now my problem is, I set up a Network Suite and send a command to let my Slave to run a task, everything still works fine with Aliases.A. But not for Aliases.B. not with namemapping or VCLObject() method. The process seems to only have generic windows properties.
The project is copied to slave with network suite so I suppose all settings including TestedApps and Namemapping are same.
I cannot install TestComplete on my slave to try object spy since my slave has to be in a LAN without access to Testcomplete license server.
As an exmaple:
I have below two functions return the same object. both works on master machine but find_form_vcl() doesn't work on slave machine( tried initiated with network suite or run testexecute locally with command line), it returns object not found. As if TestExecute doesn't recognize it as a Delphi compiled.
def find_form_Wnd():
b = Aliases.B
props = ["WndCaption"]
values = ["xxxForm"]
form = b.FindChild(props, values, 5)
return form
def find_form_vcl():
b = Aliases.B
form = b.VCLObject("xxxForm")
return form
I already made sure all instances are run with the same Windows user.
------Update on Nov.15----------
I managed to install Test Complete 11.30 on my slave machine and check the problematic process B.exe in object browser.(Using the same project copied from master).
I made a debug build with the debug info of B.exe. In the object browser it is not recognized by Test Complete as an Open applications as the other processes of my program. I am trying to figure out if there is any other variants between master and slave machine.(One thing I is the master machine has a project suite with all other projects but the slave machine only has the project for that specific application. wondering if any settings in project suite can affect that.)
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
On the slave machine, run TestExecute and then right-click on the icon in your systray. Click "Install Extensions" and check to make sure the Delphi support extension is active on that machine.
Another possiblity could be a timing problem. The object MAY be there, but calling just b.VCLObject('xxxForm') does not actually do any waiting... it may take some time for the object to be recognized. Try using the WaitVCLObject method instead and see if that improves things.
Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----
Why automate? I do automated testing because there's only so much a human being can do and remain healthy. Sleep is a requirement. So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.
Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
One more possibility, considering that
for Aliases.B. [...] The process seems to only have generic windows properties.
is that the file with the debug information for the B application (B.pdb) is not deployed (copied) to the slave machine or TestExecute cannot find it there.
/Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the suggestions.
I checked my TC's extenstions and clicked select all then OK. Unfortunately the problem remains.
Tried using the WaitVCLObject method with 10 seconds it still has the same problem. I can manualy click the window but TC is not able to detect it even it's there Visible.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the help.
Yes I put the debug info file(.tds for Delphi) with the .exe on the slave machine. I also made a debug build with debug info and TC is still not able to recognize it as a Delphi built process.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Sounds wierd...
I would recommend to open Support case via the https://support.smartbear.com/message/?prod=TestComplete form and reference this thread.
I'll appreciate it if you update here for the benefit of others with what you will end up with Support.
/Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================
