|
||
|
LoadRunner Interview Questions Intermediate Level 2 Question 1: What is the significance of Vuser_init ?Vuser_Init is an explicit action generated by Vugen to include all the statements that need to be executed only once during script execution. Everything that needs to be initialized is placed here. Question 2: What is the difference between standard log and extended log? Standard Log: Sends the subset of functions and messages sent during vuserscript execution to a log. The subset depends on Vuser type used. Extended Log: Sends the detailed vuserscript execution messages to the output log. - Parameter Substitution: logs the parameters and the values when vuser script runs. - Data returned by server: Logs all information sent from the server to the vuser. - Advanced Trace or Full Trace: Logs all of the vuser messages and function calls. . Question 3: What are the different sections of the vuser script and in which sequence these sections get executed? LR Script has following sections and gets executed in the same sequence: vuser_init: The vuser_init section is executed once, when the vuser is brought up and initialized, and contains any information necessary to enable the virtual user to log into an application. Action: The action is the part of the script that performs the iterative work of the business requirement. Action has actual code to test the functionality and performance of the application. Action can have any number of iterations. Vuser_end:The vuser_end has requests (or code) to log out the vuser from the application. Vuser_end is executed only once. Question 4: What is the difference between transaction and transaction instance in loadrunner? A LR transaction is used to measure time between executions of certain statements. A LR transaction instance is used for performance analysis. Question 5: What is Elapsed Time in Load Runner? Elapsed time is the total time taken by ramp up, Test duration and ramp down. Elapsed time designates how much time has passed since the start of the current event and is measured differently for different window as explained below: In Scenario Status Window - Elapsed time is measured from the moment you click the "Start Scenario" or "Initialize/Run Vuser?" button. In "Vuser" window it is measured form the moment Vuser enters in "running" state Question 6: In loadrunner, Which function is used to end a nested transaction? lr_end_sub_transaction is used to end a nested transaction. Question 7: In loadrunner, Explain wasted time in VuGen Replay log? A 'wasted time' is the duration spent on human/idle-waiting overhead. It is different from actual time spent on processing and displaying information. Wasted time is measured as a factor of unnecessary waiting. e.g: Action.c(49):Transaction "pqr" ended with "Pass" status (Duration: 0.5842 Wasted Time: 0.0002). Question 8: What is correlation? Explain the difference between automatic correlation and manual correlation? Correlation is used to handle the dynamic values in a vuser script. The few dynamic values could change for each user action (value changes when action is replayed by the same user) or for different users (value changes when action is replayed with different user). In both the cases correlation takes care of these values and prevents the script from failing during execution. Manual Correlation involves identifying the dynamic value, finding the first occurrence of dynamic value, identifying the unique left and right boundaries for capturing the dynamic value, writing correlation function web_reg_save_param before the request having the first occurrence of dynamic value in its response. E:g: web_reg_save_param ("corValue", "LB= value=\"", "RB=\"", "Ord=All", LAST); Automatic correlation works on predefined correlation rules. The vuser script is played back and scanned for auto correlation on failing. Vugen identifies the dynamic values wherever the correlation rules work and correlate the value on approval. Question 9: How do you run specific part of your script for a specified number of times? A specific part of the vugen script can be run for specific number by using blocks and by changing the number of iteration present in run time settings -> General -> Run Logic. Question 10:What is the difference between lr_abort and lr_exit?t? The lr_exit function allows user to exit from the script run during execution; it gives you different continuation options which include exiting vuser or just exiting the iteration and continuing next iteration. lr_exit (LR_EXIT_VUSER, LR_FAIL); lr_exit (LR_EXIT_ACTION_AND_CONTINUE, LR_FAIL); A transaction in which lr_exit is called does not appear in the controller in the Transaction Status box. It is not included in the count of passed and failed transactions. If lr_exit is called many times in the same script, whether in different actions or different iterations, it is the exit status of the last call that determines the status of the Vuser group running the script. The lr_abort function aborts the execution of a vuser script and It stops the execution of the Actions section, executes the vuser_end section, and ends the execution. When you end a run using this function, the status displayed is “Stopped.” lr_abort doesn’t have any continuation option, the vuser is exited. Previous Next |
|
FIND MORE ON LOAD RUNNER TIPS
| About Load Runner | Creating scripts in Load Runner | Load Runner scenario | LR Analysis | Performance Tuning | Performance Testing | LR Errors | Interview Question | Load Runner Tool | Correlation Practice | Site Map | |