Spike Testing

Spike Testing

Spike testing is done to check if the application can handle, if there is any sudden spike of user on the application. And it will let the customer know if the system will crash or it will handle the spike with some  degradation on the application behavior.

Difference between Spike and stress testing?

Spike Test :

  • And Spike Test is done on the system to check the behavior of the application with sudden spike.
  • So if the load is spiked up sudden the application the behavior of the infrastructure can be tested.
  • And also the Spike Test will let the customer know how spike it can handle with the current infrastructure.
  • So this type of testing important to check negative scenarios on the application.

Stress Test :

  • Stress Test is used to test the breaking point of the application.
  • And also check how many concurrent Vuser can a application handle.
  • So large data will be loaded into the application.

Tools recommended for Spike Test in performance testing.

How to add think time or wait time in Ajax TrueClient?

Adding Wait or Think Time in Ajax TrueClient Scripts.

There are different type of wait object to method present in ajax trueclient to add into the script. We will see the different option present and how they are different from each others. And also the purpose of each method. There are two ways we can add the wait in the trueclient script. So they are

  • Wait
    • It will wait for the duration provided in the wait step.
    • So the next will be triggered even if the step is ready.
  • Wait for Object
    • It will wait for the object until the object is present in page.
    • So that the previous page will wait still loading is completed.

Step 1 :

  • Launch the trueclient protocol in the Vugen.
  • And click on Develop script option in the script.
  • And record the flow , after that we can add the wait or wait for object to the script.

Ajax TrueClient Adding Transactions

Click Here to see how to record the script in Ajax TrueClient.

Step 2 :

  • Once you have recorded the flow completely. Then you can add the wait to the scripts.
  • Click on the Toolbox option present in the left side of the developer mode mode editor.
  • Under that option click on function bar.
  • And you will see the Wait and Wait for Object component present in it.

Wait Time in Ajax TrueClient

 

Step 3 :

  • Choose Wait component form the toolbox.
  • Drag and place the Wait after the step where you want it to be placed.
  • So the Wait component will be added to the script.
  • And also you can edit the Wait time in that step.
  • So you can mention how many seconds or minutes the wait step wait.
  • By default the value will be 3 seconds.

Step 5 :

  • Lets add Wait for Object in the step.
  • Choose Wait for Object component form the toolbox.
  • Drag and place the Wait for Object after the step where you want it to be placed.
  • Click on Click to Choose an Object from the Component.
  • And a finder section widow will be displayed. Where you need to select the object to wait.

Step 6 :

  • Once you select the object for which the script should be waiting.
  • You can also change the xpath of the wait object.
  • And now you can run the script.

 

Jmeter Listener

Jmeter Listener

There are different type of listeners present in Jmeter. We will see all the listeners and there usage one by one.

Aggregate Graph :
Aggregate Report :
Assertion Results
Backend Listener
BeanShell Listener
BSF Listener
Comparison Assertion Visualizer
Generate Summary Results
Graph Results
JSR223 Listener
Mailer Visualizer
Monitor Results
Response Time Graph
Saves Responses to a file
Simple Data Writer
Summary Report
View Results in Table
View Results Tree

Load Testing

Load Testing

It will help to check the application's  behavior to perform under anticipated loads on application. The objective is to identify performance bottlenecks of the application under expected load. Load Test will determine the maximum operating capacity of an application. And also determine whether current application infrastructure is sufficient or we need increase to run the application. It also give the stability of application with respect to maximum number user load. It will also determine the number of concurrent users that an application can support with any degradation of the application.

Difference between load and stress testing?

Load Test :

  • And load Test is to test the system behavior under normal workload conditions, and it is just testing or simulating with the actual workload.
  • So the load Test will not be tested with loading of data into database.

Stress Test :

  • Stress Test is used to test the breaking point of the application.
  • And also check how many concurrent Vuser can a application handle.
  • So large data will be loaded into the application.

Tools recommended for Load Test in performance testing.

Ajax TrueClient LoadRunner Tutorials

Ajax TrueClient LoadRunner Tutorial

Training Summary

Ajax TrueClient protocol in the loadrunner.  Ajax TrueClient protocol is mainly used to do the user side testing or the behavior of the browser side. So it is a heavy protocol due to which the number of load generator for the execution will be more compared to web scripts.

Syllabus


1. Tutorial  -> How to record Ajax TrueClient script in Loadrunner.


2. Tutorial -> How to add Parametrization in Ajax TrueClient script.


3. Tutorial -> How to Capture the values in Ajax TrueClient script.


4. Tutorial -> How to add Transactions in Ajax TrueClient Script.


5. Tutorial -> How to Call external C- Function in Ajax TrueClient Script.


6. Tutorial -> Adding VTS Functions to the Script.


7. Tutorial -> Different Vuser Function present in Ajax TrueClient Script.


8. Tutorial-> Interview Questions for Ajax TrueClient Script.


9. Tutorial-> Quiz related Ajax TrueClient Script.

Stress Testing

Stress Testing

Stress test is one of the test done on the application to find the breaking point of the application. It will determine how much load the application can handle. How will the response time and resource behavior when the extreme load is applied on the system. Important it will give the customer the need confidence how much load the system can handle with existing resources.

Difference between stress and load testing?

Stress Test :

  • Stress Test is used to test the breaking point of the application.
  • And also check how many concurrent Vuser can a application handle.
  • So large data will be loaded into the application.

Load Testing :

  • And load Testing is to test the system behavior under normal workload conditions, and it is just testing or simulating with the actual workload.
  • So the load Testing will not be tested with loading of data into database.

Tools recommended for Stress Test in performance testing.

Volume Testing

Volume Testing

Volume Test is used to test large number of data populating in database for a period of time or for a particulate time. And check if the application is able to handle the volume of data getting loaded into the application. And also see the overall application behavior is monitored. So the objective is to check software application's performance under varying database/batch volumes.

Need for Volume Testing.

  • Volume Testing is done to check if the application can handle large data loading into the database.
  • So will test how will behaviors during the test.
  • Handling of large data loading into the database.
  • And also the utilization of CPU and memory resources.

Difference between volume and load testing?

Volume Test :

  • Volume Test is used to test large number of data populating in database for a period of time or for a particulate time.
  • And check if the application is able to handle the volume of data getting loaded into the application.
  • So large data will be loaded into the application.

Load Testing :

  • And load Testing is to test the system behavior under normal workload conditions, and it is just testing or simulating with the actual workload.
  • So the load Testing will not be tested with loading of data into database.

Tools recommended for Volume Test in performance testing.

LoadRunner Tutorials

HP LoadRunner Tutorial

Training Summary

LoadRunner is the product from Micro Focus Company currently earlier it was with HP Team. Loadrunner is the most widely used tool for performance testing as it support multiple protocol and also its user friendly compared to any other tools in the market. Here we will be seeing each part of the loadrunner and its working step by step. And also there are multiple post related to Loadrunner and at last you can test your understanding using quiz.

Syllabus


Tutorial  -> Architecture of Loadrunner and Introduction to Loadrunner


Tutorial -> Recording Options in Loadrunner.


Tutorial -> How to record web script in Loadrunner.


Tutorial -> How to do Parametrization in Loadrunner.


Tutorial -> How to do Correlation in Loadrunner.


Tutorial -> How to use Web_reg_save_param for Correlation.


Tutorial -> Loadrunner Functions


Tutorial -> Interview Questions


Tutorial-> Quiz to test your understanding on Loadrunner.


 

Run-Time Functions Present in Loadrunner

Run-Time Functions

Below are the most important list of Run Time functions present in load runner.

lr_load_dll :

  • lr_load_dll function loads a DLL (Windows) or shared object (Linux) allowing you to call an external function when replaying using the C interpreter.
  • Once you load the DLL, you can call any function defined in the DLL, without having to declare it.
  • On Windows platforms, except for the SAP GUI protocol, if you do not specify a path, lr_load_dll searches for the DLL using the standard sequence used by the C++ function, LoadLibrary.
  • Example : lr_load_dll("user32.dll");

lr_peek_events :

  • lr_peek_events function suspends the Vuser script run and checks for events before resuming.
    • Scripts written in C language perform this check internally. Therefore, there is no need to use the lr_peek_events function.
    • Scripts written in Java do not perform this check internally. Therefore, insert this function into your Vuser script at the point at which you want the Vuser to pause.
  • Example : lr_peek_events();

lr_think_time :

  • lr_think_time allows you to pause test execution during a run.
  • This is especially useful in simulating think time, the time a real user pauses to think between actions.
  • Example : lr.think_time(1);

lr_rendezvous :

  • lr_rendezvous function creates a rendezvous point in a Vuser script.
  • When this statement is executed, the Vuser program stops and waits for permission to continue.
  • This function can only be used in an action section, and not in vuser_init or vuser_end.
  • Example : lr.rendezvous("QueryRendz");

lr_continue_on_error :

  • lr_continue_on_error function specifies how to handle errors.
  • You can choose to continue running if an error occurs, or to abort the run execution.
  • To continue script execution even when errors occur, select the Continue on Error check box in VuGen's Runtime Settings.
  • Example : lr_continue_on_error(1);

lr_abort :

  • lr_abort function aborts the execution of a script .
  • It stops the execution of the Actions section, executes the vuser_end section, and ends the execution.
  • This function is useful when you need to manually abort a run as a result of a specific error condition.
  • When you end a run using this function, the status is "Stopped."
  • Example : lr.abort( );

lr.exit :

  • lr_exit function allows you to exit from the script run during execution.
  • Example : lr.exit(lr.EXIT_VUSER, lr.FAIL);

Click Here to see all the string function present in loadrunner.

Message Functions Present in Loadrunner

Message Functions

Below are the most important list of message functions present in loadrunner.

lr_debug_message :

  • lr_debug_message function sends a debug message when the specified message level is active.
  • If the specified message level is not active, a message is not issued.
  • So you can set the active message level to MSG_CLASS_BRIEF_LOG or MSG_CLASS_EXTENDED_LOG from the user interface or by using lr_set_debug_message.
  • But to determine the current level, use lr_get_debug_message.
  • Example : lr_debug_message(LR_MSG_CLASS_RESULT_DATA | LR_MSG_CLASS_PARAMETERS, "Operation failed.");

lr_error_message :

  • lr_error_message function sends an error message to product output windows log files, and other test report summaries.
  • Example : lr_error_message("Error: %s", "Unable to login to secure computing");

lr_get_debug_message :

  • lr_get_debug_message function returns the current log run-time settings .
  • But the settings determine what information is sent output.
  • The log settings are specified with the run-time settings dialog, or by using the lr_set_debug_message function.
  • Example : msg_level=lr_get_debug_message( );

lr_log_message :

  • lr_log_message function sends a message to the Vuser or agent log file (depending on the application), and not to the output window.
  • So you can use this function for debugging by sending error or other informational messages to the log file.
  • But in a standalone program such as VuGen, lr_log_message sends the message to the viewer and output.txt.
  • Example : lr_log_message ("login failed: %s", abort);}

lr_output_message :

  • lr_output_message function sends a message with the script section and line number to output windows, log files, and other test report summaries.
  • Example : lr_output_message( "We are on iteration #%s", lr_eval_string( "{iteration}" ) );

lr_set_debug_message :

  • lr_set_debug_message function changes the debug message level bitmap.
  • The message level is initially set in the script's Run-time Settings dialog box.
  • lr_set_debug_message changes the message level from the current value.
  • So, the message level in effect is the result of the Run-time Settings and all previous calls to lr_set_debug_message.
  • Example : lr_set_debug_message(LR_MSG_CLASS_EXTENDED_LOG | LR_MSG_CLASS_FULL_TRACE, LR_SWITCH_OFF );

lr_vuser_status_message :

  • lr_vuser_status_message function sends a string to the Status area of the Controller.
  • But it will also sends the string to the Vuser log. When run from VuGen, the message is sent to output.txt.
  • Example : lr_vuser_status_message( "We are on iteration #%s", lr_eval_string( "{iteration}" ) );

lr_message :

  • lr_message function sends a message to the log file and output window.
  • When run in VuGen, the output file is output.txt.
  • So use the lr_log_message instead of this function to send the message only to the log file.
  • Example : lr_message ("login failed: %s", abort);}

Click Here to see all the transaction function present in loadrunner.