Welcome to the Question and Answer site for Software Testing Professionals

You can get your queries resolved from Software Testing Professionals.

Ask a Question

Get answers and give answers to questions from other members.

View All Questions

Get votes and earn points to build your reputation in community.

View Hot Questions

What are differences between JMeter script and selenium script?

Open 1 Answers 31 Views
0 1
I learn 2 method's

1) By recording script and apply load on it  -> view result .

2) Selenium java code -> convert  into jar -> include that  jar in jmeter  -> add junit sampler script -> apply load  -> view result.

which method will give exact performance result.

and what is the difference b/w these 2 method's

1 Answer

If you talk about the results vs performances, both are used for entirely different purpose.

With JMeter, you can speedup the communication with the server and so you can make sure that specific function works fine or not based on the response. But, it does not really gaurrentee you that your UI works as expected.

Selenium simply helps you imitates user actions on the browser of your choice. So, you can write your code once and execute it on different set of browsers to make sure that all functionality works fine on all browser.

I will give you an example here.

Say, you have an application which has many Ajax calls. Now, you have a change password functionality that changes password through AJAX call. It is very important for you to verify that this AJAX works across all different browsers. So, if you would have used Selenium, you can easily say that your JavaScript code works fine.

But, using JMeter, it might complete the AJAX call. But, it does not say that your JavaScript function works across all browsers.

Hope I am clear.
answered Jan 24 by Chris Gilburg
commented Jan 24 by Abhishek (131 points)
using selenium we can do functionality testing but we can't do performance testing .
commented Jan 24 by mayur (733 points)
No, that's why we do have JMeter. Using JMeter you can trigger 1000s of users at the same time. You can do the same with Selenium as well. But, the amount of resources it requires will not make any sense to the business.
commented Jan 31 by bharatvars4567 (650 points)
@ Chris, can you tell me how to test selenium code using jmeter

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.

We have resolved 1.2k+ Software Testing queries!

Software Testing Board Weekly update

We will send you handpicked questions that you would love to answer.

View previous campaigns.

Top Contributors