These are the recorded scripts that will be played back against the test system
property ContainsCSPToken as %Boolean;
Indicates whether one or more of the URLs for this script contains a CSPToken (protected/encrypted page) property ErrorCheck as %String(TRUNCATE=1);
The code to call to see if the returned page was an error. This should in the form of a function that returns a zero or non-zero value where zero = no errors and non-zero = errors found property Name as %String(TRUNCATE=1);
A unique name for this script property OriginalPort as %String(TRUNCATE=1) [ InitialExpression = 80 ];
This is the default port that is used to communicate with the web server. It is assumed to be 80 unless otherwise specified. property OriginalServer as %String(TRUNCATE=1);
It can be overridden by any URL
This is the default web server address that will be used throughout the script. property PostRunCode as %String(MAXLEN=256,TRUNCATE=1);
It is taken from the first URL call.
The reason that we store it is so that it can be retrieved if any of the URLs throughout the script call other web servers
when it is overridden by that particular URL
The is the code that is executed at the end of each full script It should take the form of a function that returns a zero or non-zero value indicating whether the script should continue to run or not. (Zero = stop running, non-zero = continue to run the script) property PreRunCode as %String(MAXLEN=256,TRUNCATE=1);
The is the code that is executed before each run of the script. It should take the form of a function that returns a zero or non-zero value indicating whether the script can run or not. (Zero = do not run, non-zero = run script) property RandomisationGenTime as %Integer;
The date/time that the randomisation routine was automatically generated property RandomisationRoutine as %String(TRUNCATE=1);
The name of the routine that contains the randomisation code property RecordDateTime as %TimeStamp;
Date and time that this script was recorded property RecordMethod as %String(TRUNCATE=1) [ InitialExpression = "Manual" ];
This indicates the method used to build this script property TotalLengthMins as %Numeric [ Calculated ];
A calculation of how long the script would take to run based upon the delay time between the user's input and the recorded length of time for the server to reply to the request. relationship URLs as %WebStress.Scripts.URLS [ Inverse = Script,Cardinality = children ];
These are the details of each dialog between the browser and the web server that all go together to form the total script.
classmethod CacheRecorder(scriptname As %String = "", creatertn As %Integer = 0, rtnname As %String = "", debug As %Boolean = 0) as %String
Converts the output from a recorded session into a script with associated URLs etc. classmethod CheckRoutineIsValid(id As %String) as %Boolean
Requires a script name as a parameter. Note that this is stored in the recorded data after this method has been called meaning that subsequent calls to this method can be left blank and the method will re-use the last supplied name.
creatertn is either 0 (zero) or non-zero indicating whether or not an automatic randomisation base routine is to be created.
rtnname specifies the optional routine name if creatrtn is used.
classmethod GetTotalLengthMins(id As %String)
method HomeDirectory() as %String
classmethod MS2Cache(defaultnameprefix As %String = "Default_", overwrite As %Boolean = 1) as %String
Gets data from MS Access and builds our scripts classmethod MakeRtn(scriptid As %Integer, rtnName As %String = "") as %String
First you need to follow these steps:
1. Setup a SYSTEM ODBC data source and use the Microsoft Access driver to point to the .mdb file created by the Microsoft tool
2. Setup a SQL Gateway to point towards this ODBC data source
3. Use the SQL Manager to link to the following tables in the .mdb file:
These 3 steps should create the following classes:
Normally the name of the script would come from the .mdb file but a default can be supplied for the cases where the value in the .mdb file is a null string. In this case the name of the script will be the name of the default name prefix and then the group ID number
For example: if defaultnameprefix = "Default_" and the group ID is 3 then the name of the script would be 'Default_3'
The overwrite key is used so that you can overcome the problem where MS Access lets two different scripts have the same name. a ' (n)' is added to the end of the script name if overwrite is set to 0
For example the first file might be "Main Test" and the second would be "Main Test (2)"
This method can be called to automatically create the base routine for randomisation scripts. It accepts two arguments: classmethod ShowProgress(msg)
scriptid = This is the internal ID number of the script. (Required) rtnname = This is the name of the routine. (Optional). If not present this will default to "Random.Script.n"
where n is the scriptid number
Used by debug to show what's going on method TotalLengthMinsGet() as %Numeric
This is a Get accessor method for the TotalLengthMins property.
index (NameIndex on Name) [Unique];