jscript - Wrapper for TestComplete Function "FindChild" -


please forgive poor knowledge of js/jscript architecture.

i'm attempting store arguments of findchild call print debugging. i'm open other routes accomplish this, current attempt involves wrapper function, according this guide.

var findchildparamstext = "";  (function() {     var copy = findchild;     findchild = function() {            findchildparamstext = copy.arguments;        return copy.apply(this, arguments);     } })(); 

i'm having problem accessing original method copy. getmethods should into? if so, overhead become more like.

write wrapper function this:

function findchild(obj, propnames, propvalues, depth, refresh) {   // access propnames , propvalues need   ...    var result = obj.findchild(obj, propnames, propvalues, depth, refresh);   return result; } 

and replace findchild method calls in tests

obj.findchild(...); 

with custom function:

findchild(obj, ...); 

Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -