Forum Discussion
Marsha_R
6 years agoChampion Level 3
tristaanogre Any ideas about this?
- tristaanogre6 years agoEsteemed Contributor
In JavaScript this works:
function defaultParams(parm1 = 'test', param2 = 3){ Log.Message(parm1) Log.Message(param2) }
So, this tells me that the problem is not in TestComplete necessarily. The code you posted is in Python. I'm not 100% certain what the proper answer is for Python script. But I do know that, at least default "basic" data types work. An enumerated data like a key/value pair... I don't think that will work.
If you WANT to go that route...instead of a script routine, create a Keyword Operation Script Extension with a custom User Form to prompt for parameters where you can set up the pre-defined values and drop downs. See https://support.smartbear.com/testcomplete/docs/working-with/extending/script/creating/keyword-test-operations/index.html
Related Content
- 2 years agoianlop
- 11 months agoIso_Yura
- 6 years agovthomeschoolmom
- 6 months agomacheshmeh
Recent Discussions
- 2 days agovladd1