1. Create Thread group
Right click "Test plan"; Choose Add - Threads (Users) - Thread Group
Provide :
Any name; No. of Threads (Users)=1 [ It could be set as per requirement of concurrent user access ]
Ramp-up period (in sec.)=30; Loop count=1
2. Create HTTP request under Thread group
Right click Thread Group; Choose Add - Sampler - HTTP request
Provide :
Any name; Server or IP=(application host); Port=8080; Protocol=http; Method=GET
Path=(application path) Example: myApplication/myServlet
CHECK Follow Redirects; CHECK Use keepAlive; CHECK Retrieve all embedded resources from HTML;
CHECK Use concurrent pool. size=4
a. Add session management (Cookie handling)
Right click HTTP request; Choose Add - Config element - HTTP cookie manager
Provide any name
b. Add headers to the HTTP request (If application is expecting some request headers)
Right click HTTP request; Choose Add - Config element - HTTP header manager
Provide :
Any name
Header stored = Provide request headers in key/value pairs.
c. Add Authorization parameters to the HTTP request (if application using browser authorization)
Right click HTTP request; Choose Add - Config element - HTTP Authorization Manager
Provide :
Any name; Authorization stored = provide username and password
3. View results
View results in table
Right click "Test plan"; Choose Add - Listener - View Results in Table
View results tree
Right click "Test plan"; Choose Add - Listener - View Results Tree
Aggregate report
Right click "Test plan"; Choose Add - Listener - Aggregate Report
Aggregate Graph
Right click "Test plan"; Choose Add - Listener - Aggregate Graph
4. Run test
Choose Test plan and click Run icon (Ctrl + R)
View test result in added listener.
No comments:
Post a Comment
Note: only a member of this blog may post a comment.