Access Performance Data
In order to access the results of a performance test in code, it will be necessary to create an execution extension library. The approach to this problem is to use a performance test list to execute one or many performance tests. Then at the end of the execution to collect the data from each one of the performance test results files.
Preconditions
- Add a reference to the VS project for the following library located in product installation \bin folder:
- Telerik.TestStudio.Interfaces.dll
- Include in the project listed below namespaces:
- ArtOfTest.WebAii.Design.Execution.Profiler
- ArtOfTest.WebAii.Design.Execution.Profiler.Storage
- If not present - create C:\temp directory, where the new result file will be placed
Sample Code
The following extension class will store the full path to each performance test result and its ID in a Dictionary data structure. This structure will be updated after each test completion in the OnAfterTestCompleted() method. Then at the end of the test list execution in OnAfterTestListCompleted() method - all files will be opened one by one to collect necessary data and save it in C:\temp\lastPerformanceResults.txt file.