Keyword Project - Convert from Python to JavaScript
Short Question - How do you convert a Keyword Project recorded using Python as the underlying language to JavaScript?
Long Background - When we were originally creating Projects years ago - we experimented with using different underlying languages for our Keyword Projects. Quickly we decided to go with JavaScript as our standard as it appeared to be the most universal. Since what we were reading at the time stated that the underlying language should have no impact on actual function - we didn't bother redoing anything we had in Python.
Now we are running into issues which require some scripting (i.e. - Capture an Order number from a screen, then plug that number into another function). We don't want to have to find solutions for both languages. As JavaScript is our standard, we want to convert our Python Projects.
Anyone know how?
Hi Rich,
> Are we out of luck?
Unfortunately, yes, you are.
However, I believe that unless you were using something that is very specific to Python, the conversion should not be that difficult.
Personally I convert from time to time my code that I created in VBScript, DelphiScript and JScript and the process is quite straightforward. (Tip: my preference is to use the means provided by TestComplete instead of native functionality provided by the given scripting language whenever possible. (E.g. functions to work with date, time, strings, etc.) This significantly simplifies future conversion.)
Another option that you may consider is to create Script Extension and move common generic code to there. Script Extensions are not ideal but can be used from projects that are based on different scripting languages.