WR / VBScript Tip - Potentially Powerful
The following post is a response to another post.
I am wondering if anyone has explored using vbscript and WinRunner working together. I'm thinking the potential is enormous as follows:
1) What if you could multi-task VBScript or JScript with WinRunner, such that you could accomplish things with VB/Jscript that are not easily accomplished in WinRunner?
1.1) I'm thinking if you could multi-task (easily), then you could for example, have VBScript do your database transactions whilst WinRunner does something else. Example: WinRunner is driving a gui client that reads/writes a database. Perhaps while driving the client, VBScript is off doing some setup of data and/or getting results.
2) What if you could use the object features of VBScript to get at those objects that WinRunner can't get at (without rewriting QuickTest)?
From that post reference (you need to be able to run VBscript:
<BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>
Example of calling something in "another language"
Create a WinRunner script that has only the following TSL statement:
dos_system("c:\\aaa.vbs -WRunner -Is -Cool");
Create with an editor (notepad) the following VBS script:
Dim objArgs, i, MyMessage
Set objArgs = WScript.Arguments
For i = 0 to objArgs.Count - 1
MyMessage = MyMessage & objArgs(i)
Save this as:
Run the WinRunner script.
If anyone has done anything of this nature, you are welcome to share. Also, if there is no potential here, let me know. Please critique!
Airborne requirements seldom land and are exempt from gravity.
Re: WR / VBScript Tip - Potentially Powerful
You could probable integrate Perl also, or whatever scripting languages have been adapted to the O.S. via WSH.
I'm investigating the matter very seriously, and I think that there is enormous potential. Thereupon, I've already decided to dump TestDirector.
As I said, I have used scripts to take advantage of the FileSystemObject. I'm looking into other advantages.
I'd probably dump WinRunner, if there were a free-ware API to manipulate GUIs. I can do without the 'Record' mechanism. I'll start a post forthwith on the subject. Maybe a script to access those MI WR dlls.