The maintenance period for Scroll Versions has expired on Nov 14, 2014. Make sure to get product updates and support, and extend your maintenance today.
You can further extend StresStimulus run-time by creating an external component. An external component traps StresStimulus run-time events to extend its functionality.
To create an external component implement the
StresStimulus.Extensibility.IExternalComponent interface. It has the following interface definition:
- OnTestStart(): Use this method initialize any test specific objects that will be used during the test, or to run any pre-test script (such as cleaning previously created database records).
- OnTestEnd(): Use this method to clean up any objects used during the test or run any post-test script.
- OnBeforeRequest(): This is called before a request is sent. It receives an instance of RuntimeSession object that can be used to customize the request headers and body. This method is called after all parameters have been applied to the request.
- OnAfterResponse(): This is called after a response is received. It receives an instance of RuntimeSession object to read the response headers and body for further automation.
- OnAfterIteration(): This is called after an iteration is complete. It receives an instance of RuntimeVU object to read the VU properties.
The RuntimeSession class has access to the run-time session object that has access to request and response data. It contains the following properties and methods:
The RuntimeVU class has access to the run-time VU object. It contains the following properties and methods:
See the subsequent section for examples of external components.
- No labels