Go to Declaration and Find usages options not working
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Go to Declaration and Find usages options not working
Hi,
I am currently facing two problems inside script editor in TestComplete 14.10,
Problem 1:
Go To Declaration shown disabled in script routine's context-menu when the routines was actually written inside the class
For ex:
In unit1.py
class test: def method1(): Log.Message("Hello World")
In unit2.py
from unit1 import test def sampletest(): test.method1()- right click on 'method1()' and see the option 'Go to Declaration' shown disabled, aslo Ctrl clicks not working
Problem 2:
Find usages not working for methods inside class
consider the same above example,
right click on 'method1()' inside class 'test' in unit1.py
Click on 'Find Usages' - nothing returns, but that method actually used in unit2.py
Solved! Go to Solution.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
While you can use classes in Python in TestComplete, TestComplete is not designed to be a full development IDE of Python. You are writing Python script, not full Python, so the parsing and inclusion of things is a bit different.
Technically speaking, you don't need the class at all. If you pull Method1 out into just a method function without a class and import the method, it will work just the same.
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
