Posts

Showing posts with the label non-functional testing

JMeter Quick Hacks

Add JMeter application to PATH variable Windows machine Open the System Properties window and click the Environment Variables button. In the System variables section, locate the Path variable, select it, and click Edit. In the Edit Environment Variable window, click New and add the full path to the bin directory where JMeter is located (e.g., C:\apache-jmeter\bin). Mac/Linux machine Open a terminal window. Edit your shell profile file (depending on the shell you're using, this could be .bashrc, .bash_profile, .zshrc, etc.). For example, if you're using Bash , run: nano ~/.bash_profile If you're using Zsh , run: nano ~/.zshrc Add the following line to the end of the file, replacing the path with your JMeter bin directory: export PATH=$PATH:/opt/apache-jmeter/bin Save the file and exit Increase Heap Size of JMeter Application For windows -  Modify the below command the jmeter.bat file in "jmeter/bin" folder Ex - set HEAP=-Xms1g -Xmx1g -XX:MaxMetaspaceSize=25...

Workload Modelling for performance tests using little's law formula

 In the context of performance testing, Little's Law is often applied to analyze and understand system behavior under load. Here's how it relates to performance testing: 1. **Throughput (\(\lambda\)):** In performance testing, throughput refers to the rate at which a system can handle a certain number of transactions or requests per unit of time. This can be measured in transactions per second, requests per minute, etc. 2. **Response Time (\(W\)):** Response time in performance testing represents the time taken by the system to respond to a request, typically from the moment the request is sent until the response is received. It's often measured in milliseconds or seconds. 3. **Concurrency or Load (\(L\)):** In performance testing, concurrency or load represents the number of active users or transactions within the system at a given point in time. Little's Law can be applied in performance testing scenarios to derive various insights: - **Understanding System Behavior:*...

Why Software Performance Testing?

 Performance testing is required to ensure that a software application or system meets the expected performance standards and can handle the anticipated workload. Here are some reasons why performance testing is necessary: 1. Evaluate system response: Performance testing helps assess how the application performs under different conditions, such as high user loads or heavy data volumes. It measures response times, throughput, resource utilization, and scalability to determine if the system meets performance goals. 2. Identify bottlenecks: Performance testing helps identify performance bottlenecks, such as slow database queries, inefficient algorithms, network latency, or hardware limitations. By pinpointing these issues, developers can optimize the system to improve performance. 3. Ensure stability under stress: Performance testing involves subjecting the system to stress by simulating high user loads, concurrent transactions, or data-intensive operations. This helps identify potent...

Correlation in JMeter

Correlation is the process of extracting information from the response of one request and using it in the request of another step at runtime. This is necessary when dynamic values from the response of previous requests needs to be passed in subsequent requests. Correlation is used in performance testing for dynamic websites, where the server responds to dynamic variables that keep on changing every time Correlation can be achieved using below components on need basis and these are part of post processor component group . Boundary Extractor :  It can be used when we have fixed right and left boundary of the dynamic value which needs to be captured.  Regular Expression Extractor : It can be used capture dynamic value based the regular expression. JSON Extractor :  It can be used capture dynamic value when the response is in JSON format. XPath/Xpath2 Extractor :  It can be used capture dynamic value from any HTML element using HTML expression. Xpath2 Extractor...

Create JMeter test plan for web page

To create a JMeter test plan for web testing, follow these steps: Create a Test Plan: A test plan is a container for running tests. It defines what to test and how to go about it. A complete test plan consists of one or more elements such as thread groups, logic controllers, sample-generating controllers, listeners, timers, assertions, and configuration elements. A test plan must have at least one thread group. Add a Thread Group: Thread Group elements are the beginning points of any test plan. All controllers and samplers must be under a thread group. The thread group element controls the number of threads JMeter will use to execute your test. You can configure the number of threads, ramp-up period, and the number of times to execute the test. Add Default HTTP Request Properties: You can define the default settings for your HTTP requests. This is where you specify the Web Server's Server Name/IP and other default settings. Add HTTP Requests: In this step, you specify the tasks tha...

What is Software Non-functional Testing and its significance ?

 Non-functional testing is a type of software testing that focuses on evaluating the non-functional aspects of a system rather than its specific functionalities. It is performed to assess the performance, reliability, usability, scalability, and other quality attributes of a software application or system. The primary goal of non-functional testing is to ensure that the software meets the desired levels of performance, usability, and other non-functional requirements. Here are some key aspects and significance of non-functional testing: 1. Performance: Non-functional testing helps identify how well a system performs under specific conditions, such as high load, stress, or concurrent user access. It aims to uncover performance bottlenecks and determine if the system meets response time, throughput, and resource utilization requirements. 2. Reliability: This testing evaluates the system's stability and ability to perform consistently over time. It includes testing for fault tolerance...

Software Non Functional testing types

 Non-functional testing involves evaluating the performance, reliability, usability, security, and other non-functional aspects of a software application. Some common types of non-functional testing: 1. Performance Testing: This type of testing assesses the responsiveness, scalability, and stability of a system under different load conditions. It includes tests like load testing, stress testing, endurance testing, and scalability testing to identify performance bottlenecks and ensure the system meets performance requirements. 2. Load Testing: Load testing measures a system's performance under expected user loads to determine its capacity limits and response times. It helps identify performance degradation, resource utilization issues, and potential bottlenecks when multiple users access the system simultaneously. 3. Stress Testing: Stress testing evaluates the system's behavior under extreme conditions, such as high user loads, limited resources, or unfavorable environmental fa...

Kickstart with Jmeter tool

JMeter is an open-source, Java-based performance testing tool that can be executed via either its graphical user interface (GUI) or the command-line interface (CLI). Below lists shows protocol supported by JMeter tool Web – HTTP, HTTPS SOAP / REST Web services FTP Database via JDBC LDAP Message-oriented middleware (MOM) via JMS Mail - SMTP(S), POP3(S) and IMAP(S) Native commands or shell scripts TCP Java Objects   Installation Steps:  1. Download binary file from JMeter official page – https://jmeter.apache.org/download_jmeter.cgi . 2. Unzip the file and navigate to the bin folder inside file directory.      For Windows subsystem – use “ jmeter.bat ” file to launch the application.     For Linux subsystem – use “ jmeter.sh ” file to launch the application. 3. Download plugin manager from link- https://jmeter-plugins.org/install/Install/ and copy that into “ lib/ext ” directory, then restart JMeter.  4.You're good to use the JMeter tool...

Simulate Performance Test Scenario with JMeter

This page talks about how to create Test script for load testing, Endurance(soak) testing, spike testing and stress testing using JMeter tool.   Steps to create Script for web application - 1. Choose web test plan template from JMeter test plan section. 2. Use below configuration to simulate login, actions and logout transactions which is a typical use case of web test plan.           Follow the below steps sequentially. Add Simple controller under thread group, add login requests inside it. Add Runtime controller and actions which you want to run for specified time. Add simple controller, keep logout requests inside it.   3. Make sure to complete other performance test script best practices like correlation, parameterization, and naming convention.  3. Save the script and you are good to go. This script will do single login and runs the actions request for specified amount of time, after that logout step executed.   4. For Load testing...