JMeter Beginner Tutorial 30 - JMeter Selenium Webdriver sampler

Поділитися
Вставка
  • Опубліковано 15 жов 2024

КОМЕНТАРІ • 375

  • @MrJBUK1
    @MrJBUK1 2 роки тому +1

    Not many people on UA-cam doing such a nice demos. It’s to the point and shows full knowledge on this topic. Very nice demo. Spot on.

  • @sawankandavalli8901
    @sawankandavalli8901 3 роки тому

    Hi Raghav, Thank you so much for all the tutorials. It is helping me a lot and I am learning a lot from your videos.
    I found that there is an option to select "use chrome headless mode" in chrome driver config in jmeter which will allow us to run the load test for as many thread users without opening the actual browser. You can plan a new video for it if you are interested.
    Again thank you so much for all the great videos!!

    • @RaghavPal
      @RaghavPal  3 роки тому +1

      Hi Kumar, will plan on this

  • @rohitsethi2085
    @rohitsethi2085 5 років тому +2

    It's a nice explanation....very easy steps.....waiting for more videos on this...Thanks Raghav :)

  • @truptisagarikasahoo3528
    @truptisagarikasahoo3528 4 роки тому

    After searching a lot, finally I got this video which is most useful. Thanks a lot Raghav.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Most welcome Trupti

    • @kumudgoel6520
      @kumudgoel6520 3 роки тому

      @@RaghavPal can we use complete java code in jmeter rather changing the code as javascript language

  • @spotnuru83
    @spotnuru83 2 роки тому

    I learn new things from your channel, nice to have you here explaining things, appreciate it! I have one question here, cant we use existing selenium scripts directly instead of writing code in JMeter?? that will be of great help

    • @RaghavPal
      @RaghavPal  2 роки тому

      Using existing scripts as it is may be difficult, you will need some changes and do it as shown

  • @guddetes7208
    @guddetes7208 Рік тому

    Hi Ragav, this is an wonderful session and thanks for the same. But in this session you missed to explain how to capture the response time for each transaction. Could you please help how to capture the responses for every transaction. Thanks!

  • @VasilisAnagnostou
    @VasilisAnagnostou 10 місяців тому

    Excellent work once again Raghav! Thank you!

  • @DevikaKrishnaKumar
    @DevikaKrishnaKumar 4 роки тому +1

    Hi Raghav, This is very helpful video .
    I have this requirement in my project as well . But the load is high . Is there a way to run it without the browsers like an ideal load test. Also would you happen to know a solution for this - a tool or a scripting method where the scripts can be used for both automation functional and Performance testing without having to rework the scripts -Scripting needs to be done only once for both type of testing .

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Devika, yes, you should run it without the browser. JMeter is for server side performance analysis and will not be very efficient if you do client side testing.
      Usually the needs for a performance test is different from a functional test. When it comes to API we can still use the same tests for both functional and performance and tools like SoapUI have the option. For GUI browser testing I don't think we have something to handle both directly.

  • @pratimchoudhury8638
    @pratimchoudhury8638 4 роки тому

    Nice video Raghav. Just wondering, can't we utilize existing JMeter scripts here, instead of building a new one since I don't know much about Java scripting?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Pratim, this is for client end performance testing. For server side testing as we have done in earlier session, this is not required. You can also skip as it is standalone video

    • @pratimchoudhury8638
      @pratimchoudhury8638 4 роки тому

      Thank you :)

  • @sowjanyalakkakula3618
    @sowjanyalakkakula3618 4 роки тому +1

    Hi Raghav, That is a beautiful explanation. Please may I ask how we use webdriver sampler using Gecko driver for Login to a web application,

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Sowjanya, the process will be same, You will need to add geckodriver.exe. Moreover, I will suggest if you want to test performance of a web application you can do without Se in JMeter.

  • @himasindhu7320
    @himasindhu7320 2 роки тому

    Hi Raghav.. Thanks for this wonderful video. We are doing scripts using this Web driver sampler in our project now.. How do we run this script from command line? Also, can we generate a HTML report for this? Please let me know

    • @RaghavPal
      @RaghavPal  2 роки тому +1

      Hi Hima, yes, you can run and generate html report from cmd - ua-cam.com/video/aHV5IizW7u4/v-deo.html

    • @himasindhu7320
      @himasindhu7320 2 роки тому

      @@RaghavPal Thanks much Raghav

  • @psaranya6662
    @psaranya6662 6 місяців тому

    Hi Raghav ,thanks a lot for the video.I did try to.configure the same in my JMter 5.6.2 with driver vesion compatible to by chrome 123 and installed selenium jars having 4.3.x library. But while running , I'm seeing error saying " Browser has not been configuree try adding atleast one webdriver in threadgroup".Can u pls suggest here

    • @RaghavPal
      @RaghavPal  6 місяців тому

      Saranya
      Let's troubleshoot the issue you're facing while configuring Selenium WebDriver in JMeter. The error message you're encountering indicates that JMeter is unable to find a configured WebDriver instance in your test plan. Here are some steps to resolve this:
      1. Add WebDriver Sampler:
      - First, ensure that you have added a WebDriver Sampler to your test plan. This sampler allows you to execute Selenium scripts within JMeter.
      - If you haven't added it yet, follow these steps:
      1. Right-click on your Thread Group (or any other appropriate test element) in the JMeter tree.
      2. Select Add > Sampler > WebDriver Sampler.
      3. Configure the WebDriver Sampler with the necessary details (e.g., browser type, script, etc.).
      2. Configure WebDriver in Thread Group:
      - The error message suggests that you need to configure at least one WebDriver instance in your Thread Group.
      - To do this:
      1. Right-click on your Thread Group.
      2. Select Add > Config Element > WebDriver Config.
      3. Specify the WebDriver executable path (e.g., ChromeDriver) and other relevant settings.
      4. Save your changes.
      3. Check ChromeDriver Compatibility:
      - Ensure that the ChromeDriver version you're using is compatible with the Chrome browser installed on your system. Mismatched versions can cause issues.
      - Download the appropriate ChromeDriver version from the official website and place it in a location accessible by JMeter.
      4. Check JMeter Log for Errors:
      - Run your test plan in non-GUI mode (without the JMeter UI) to see if there are any additional errors.
      - Check the JMeter log file (`jmeter.log`) for suspicious entries related to WebDriver or ChromeDriver.
      5. Verify RMI Configuration:
      - If you're running your test in distributed mode (using remote servers), ensure that the RMI (Remote Method Invocation) configuration is correct.
      - Verify that the slave machines are properly configured to execute WebDriver scripts.
      6. Use Groovy for Scripting:
      - Consider using Groovy as the scripting language for your WebDriver Sampler. Since JMeter 3.1, Groovy is recommended for scripting due to performance reasons.
      - In the WebDriver Sampler, select Groovy as the language and write your script accordingly³.
      7. Set ChromeDriver Path:
      - If you're using ChromeDriver, set the path to the ChromeDriver executable in JMeter.
      - You can pass the ChromeDriver path as a JMeter property using the `-J` option when running JMeter from the command line:
      ```
      jmeter -n -t YourTestPlan.jmx -JChromeDriverPath=/path/to/chromedriver
      ```
      - In your test plan, reference the property using `${__P(ChromeDriverPath)}` in the WebDriver Config⁴.
      Remember to verify each step carefully, and make sure your WebDriver Sampler, WebDriver Config, and ChromeDriver settings are correctly configured.

  • @mitgupta6891
    @mitgupta6891 4 роки тому

    Hi Raghav. Is there is a way to allow cam and microphone controls in JMeter WebDriver Sampler. I have below Selenium code for that already which works but I don't know how to pass that to the sampler
    ChromeOptions options = new ChromeOptions();
    options.addArguments(Arrays.asList("disable-infobars", "ignore-certificate-errors", "start-maximized","use-fake-ui-for-media-stream"));
    WebDriver driver = new ChromeDriver(options);

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Mit, I have not done this and will need to take online help

  • @amitkorey4204
    @amitkorey4204 5 років тому

    Thank you sir. You are too good and explanation u r giving is always very clear and easy to learn.

  • @SnoopBok
    @SnoopBok Рік тому

    Nice demo. Although my Chrome browser is starting but immediately closing. Any suggestions what might be the problem? (I installed the right chromedriver that matches my chrome version).

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi,
      There could be several reasons why your Chrome browser is closing immediately after starting in JMeter Webdriver Sampler. Here are a few things you can check:
      Check the code in your Webdriver Sampler: Make sure that your code is not closing the browser window immediately after opening it. Look for any driver.quit() or driver.close() statements that might be causing the browser to close.
      Check the chromedriver logs: Set the logging level to DEBUG in your JMeter Webdriver Sampler configuration and then run your script. Check the logs to see if there are any error messages that could explain why the browser is closing.
      Check for any anti-virus software: Sometimes anti-virus software can interfere with the execution of chromedriver. Try disabling your anti-virus software and see if the problem persists.
      Check for any conflicting plugins or extensions: If you have any plugins or extensions installed in Chrome, try disabling them and see if that resolves the issue.
      Check for any compatibility issues: Make sure that your chromedriver and Chrome browser versions are compatible with each other. You can check the compatibility matrix on the chromedriver website.
      Try running your script on a different machine: If none of the above steps resolve the issue, try running your script on a different machine to see if it's a problem with your local environment.
      Hopefully, one of these steps will help you to identify and resolve the issue

  • @abhiikr8694
    @abhiikr8694 2 роки тому

    Hi Raghav, when i record web application through Jmeter, some Samplers contain dynamic values but after play the Samplers ,in view result tree listeners ,i don't get any error or fail Sampler, still i need to apply correlation to extract dynamic values or i can get correct result in html report without applying correlation ?

    • @RaghavPal
      @RaghavPal  2 роки тому +1

      Check with Step by Step Debugger - ua-cam.com/video/7JI3GD0ifTw/v-deo.html

  • @alisherkhidirov0224
    @alisherkhidirov0224 2 роки тому

    Hi Raghav. Thank you for this video , I have a question regarding the fact that I did everything as you showed, but my browser does not start. It opens and closes quickly and I don't see any activity on the browser. What could be wrong? I am a Mac user.

    • @RaghavPal
      @RaghavPal  2 роки тому

      Hi Alisher, will need to check logs

  • @sumitsaha9782
    @sumitsaha9782 4 роки тому +1

    Thanks Ragav for the tutorial. I would like to ask you that to reduce the consumption of memory for opening browsers, can we use Headless browser and do the same activity ?

    • @RaghavPal
      @RaghavPal  4 роки тому +2

      Hi Sumit, yes you can. Try stackoverflow.com/questions/52834398/how-to-use-headless-browser-via-jmeter-gui

  • @megham5623
    @megham5623 5 років тому

    Hi Raghav,
    I started following your videos after watching this jmeter tutorials. Thanks a lot for a great explanations.
    I wanna ask some doubts, please try to help me out.
    1. Im trying to do performance test for one app. Its react based app so i decided to use Http request(for 99 user) and webdriver sampler for (1 user) amoung 100 users load. Is this a ryt approach?.

    • @RaghavPal
      @RaghavPal  5 років тому +2

      Hi Megha, JMeter is a server side performance testing tool. i.e. when you run your requests with JMeter, it captures the metrics of network communication and does not check the client side performance. Like in case of web application, browser is a client. It will not check browser rendering time etc. Now using webdriver sampler we can also check client performance to some extent, but is not very efficient, I will suggest to use JMeter for server side performance (without selenium webdriver plugin) and if required you can check client performance separately.

    • @megham5623
      @megham5623 5 років тому +1

      @@RaghavPal Thank you so much for your suggestion and reply. It means a lot.

  • @prashantht.v8289
    @prashantht.v8289 5 років тому +1

    Hi Raghav, I tried replicating the same in my local. But when I try to run, It just opens the chrome browser, But does not enter the url "google.com" in the browser. It gives this exception in the response:
    javax.script.ScriptException: In file: inline evaluation of: ``WDS.sampleResult.sampleStart() WDS.browser.get('www.google.com') WDS.sam . . . '' Encountered "WDS" at line 2, column 1

    • @RaghavPal
      @RaghavPal  5 років тому +1

      Hi Prashanth, pls try adding a semicolon at the end of each line
      Can also try to add import statements
      import org.openqa.selenium.WebDriver

  • @prasannas4580
    @prasannas4580 2 роки тому

    Hi Raghav, thanks for the video, kindly let me know how to go about load test using JMeter with selenium embed in it

    • @RaghavPal
      @RaghavPal  2 роки тому

      Hi Prasanna, not sure what is meant by Selenium embedded, In general, it may not be an efficient process

  • @kamesh527
    @kamesh527 5 років тому

    Hi Sir, very good videos on JMeter which is self - learning. While using the WebDriver Sampler for testing the web application, I want to test multiple pages by navigating to each. I have created a sampler for log in page of a web application. When I run the script, it gives the dashboard report of that webdriver sampler( for login page). Similarly I want separate response times, etc for each page in the web application. How should I create the webdriver sampler ...Each sampler for each page I desire or a single sampler for all the pages in a web application. I want this to be done using a WDS as this seems to be working well for my application.
    Thanks in Advance.

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Divya, You can create diff samplers for diff pages.

  • @anangphongthuyviet9066
    @anangphongthuyviet9066 4 роки тому

    Do you know how to by pass "security SSL" on Firefox?
    I got the issue that the warning message SSL certification displays at first entry the URL. I tried to set Capability however I don't know how to set it in WDS.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi, will need to check online for this

  • @Karim_Hosny
    @Karim_Hosny 5 років тому +1

    Hi Raghav, Thanks for this great lecture but i have question ,
    i chooses to run the script in headless mood but when i set the number of threads to 100 user , i found out alot of timeout errors and after investigating i found out that jmeter using a chromedriver.exe and browser window in background for each thread , which means 100 chromedriver.exe and 100 browser window which effected in PC CPU and Memory.
    So how i can fix this and make it use 1 chromedriver.exe or help with this issue?

    • @RaghavPal
      @RaghavPal  5 років тому +1

      Hi Karim, generally speaking, if you need to do proper client-side performance testing, JMeter might not be a good option for that. Pls check - www.quora.com/What-are-the-client-side-performance-testing-and-tool

  • @ArpanaKumariBE
    @ArpanaKumariBE 3 роки тому

    Hi Raghav, very helpful videos. However when I try to setup the in jmeter, i am getting SSLHANDShakeException. Could you please help how to resolve it. I am using company provided machine.

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Arpana, it can be due to your java on the system, Can check this
      stackoverflow.com/questions/32009083/javax-net-ssl-sslhandshakeexception-handshake-failure-when-using-jmeter-with-ss
      sqa.stackexchange.com/questions/40734/jmeter-how-to-resolve-javax-net-ssl-sslhandshakeexception-error

  • @yuktibaheti3412
    @yuktibaheti3412 Рік тому

    Hello Raghav, I downloaded the selenium webdriver jar yet i dont get jp options in sampler or config element. Please let me know what is the resolve in this case

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Yukti,
      The issue you are encountering is likely because the selenium-java-client-driver jar file is not properly installed or configured in Apache JMeter. Here are the steps to resolve this issue:
      Make sure you have the correct version of the jar file:
      Check the version of Apache JMeter you are using.
      Download the appropriate version of the selenium-java-client-driver jar file that is compatible with your version of JMeter.
      Add the jar file to the JMeter classpath:
      Copy the selenium-java-client-driver jar file to the lib folder of your Apache JMeter installation.
      Restart Apache JMeter for the changes to take effect.
      Verify the jar file is properly loaded:
      In Apache JMeter, go to Options > Plugins Manager.
      In the Plugins Manager window, look for the selenium-java-client-driver plugin in the list of installed plugins. If it is not listed, then the jar file is not properly installed.
      Import the relevant classes in your JMeter script:
      In your JMeter script, right-click on the Test Plan and select Add > Sampler > JUnit Request.
      In the JUnit Request sampler, select the Classname field and click the Browse button.
      Navigate to the org.openqa.selenium.remote package and select the relevant classes, such as RemoteWebDriver.
      If you still don't see the options you expect, make sure you have installed the correct version of the jar file and that it is properly configured in Apache JMeter. If the issue persists, you may want to try reinstalling the jar file or updating Apache JMeter to the latest version

  • @shreejitanakrani4550
    @shreejitanakrani4550 2 роки тому

    Hi Raghav, How many threads can we execute at a set time? because it will open that many browsers at the same time.

    • @RaghavPal
      @RaghavPal  2 роки тому

      It depends on the system configurations and resources

  • @gustavoherrera7859
    @gustavoherrera7859 3 роки тому +1

    Good day Mate
    do you know or have documentation about how to integrate automation tests made by C# selenium and integrate them with Jmeteer ?
    I really appriciate your help

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Gustavo, not yet on this topic

  • @victor3848
    @victor3848 3 роки тому

    04-02-21 just try out your tutorial it's working great. thank you for this awesome tutorial. Can i use headless like HtmlUnitDriver . I want to use in my company. do you know how many concurrent user i can go up to using this headless? and is it a better approach? & we are just doing 5-10 very important script that's all . what do you recommended? please any help will be greatly appreciated.

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Victor, you can try, although JMeter is not a very good option for client side performance testing

  • @girishshenoy8509
    @girishshenoy8509 Рік тому

    After installing the Selenium/WebDriver Support plugin, I am still unable to add chrome driver config element. Can you please help?

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Girish, will need to see the logs and error you are getting

  • @GiorgiShavkatsishvili
    @GiorgiShavkatsishvili 5 років тому +2

    Hello Raghav!
    I want to know, how can I measure page load times ? For example I want to make an automated test and then measure each visited page and calculate its load time ? Is it possible using JMeter and Selenium ?

    • @RaghavPal
      @RaghavPal  5 років тому +1

      Hi Giorgi, I believe I replied you on email. Adding here for everyone's benefit. I believe you want to record the page load time using Selenium.
      There are some tools for that - ua-cam.com/video/XMFrNla8bHI/v-deo.html
      Now Selenium ideally is a pure functional testing library, but you can record time for page load.
      Here are some links to help:
      stackoverflow.com/questions/37460214/how-to-measure-response-time-for-both-loading-and-search-time-for-a-website-se
      www.quora.com/How-can-I-measure-page-load-times-with-Selenium

    • @GiorgiShavkatsishvili
      @GiorgiShavkatsishvili 5 років тому +1

      @@RaghavPal Thank you Raghav, I've received email too. Thanks for your help.

  • @jeyabalageorge4945
    @jeyabalageorge4945 2 місяці тому

    Hi Raghav,
    Excellent video! I have created a script and it is all working fine in local. Do you have any video covered for remote driver config. I have done that as well, but my script is failing with 500 error on every samplers. Do you know why?

    • @RaghavPal
      @RaghavPal  2 місяці тому

      Can check all JMeter lectures here - automationstepbystep.com/

    • @jeyabalageorge4945
      @jeyabalageorge4945 2 місяці тому

      @@RaghavPal Awesome! thank you so much! Your tutorials are very clear and useful, great knowledge share! Appreciate that. :)

  • @diegonovoa5901
    @diegonovoa5901 Рік тому

    For some reason on my Jmter version 5.4.1, Chrometab in Chrome Driver conf not appearing sir, any suggestion would be really helpfull, thanks

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Diego,
      If the Chrome tab is not appearing in the Chrome Driver Config in JMeter, it's likely that the Chrome Driver executable is not in the correct location or is not properly configured. Here are some steps you can try to resolve the issue:
      Check the location of the Chrome Driver executable: Make sure that the Chrome Driver executable is in the correct location. The executable should be in the JMeter bin folder (e.g., apache-jmeter-5.4.1/bin), or in a folder specified in the system path environment variable.
      Check the version compatibility: Make sure that the version of the Chrome Driver executable matches the version of your Chrome browser. You can download the latest version of Chrome Driver from the official website at sites.google.com/a/chromium.org/chromedriver/downloads.
      Restart JMeter: Sometimes, simply restarting JMeter can resolve configuration issues.
      Verify the path to Chrome Driver in the configuration: In the Chrome Driver Config element in JMeter, verify that the path to the Chrome Driver executable is correct. The path should be specified in the "Chrome Driver executable" field. You can browse to the location of the Chrome Driver executable by clicking the "Browse" button next to the field.
      Check the log file: If the above steps do not resolve the issue, you can check the JMeter log file for any error messages related to Chrome Driver. The log file is located in the JMeter bin folder and is named jmeter.log.
      I hope these suggestions help you resolve the issue with the Chrome tab not appearing in the Chrome Driver Config in JMeter

  • @itsme12381
    @itsme12381 3 роки тому

    Hi, When I run the tests with webdriver sampler, I noticed from Task Manager that it piles up the chromedriver.exe instances. Tests are over but chromedriver.exe instances not released from memory. is there method like WDS.browser.dispose() ?

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Amir, I will need to check on that, In general, JMeter is not very effective for client side performance testing.

  • @pb6096
    @pb6096 4 роки тому

    Hi Raghav,is it possible to use Blaze meter recorders selenium .yaml file instead of Katalon recorder scripts ,.If not what is the use of blaze meter selenium .yaml files ??
    Appreciate for your reply.
    Thank you 🙏🏿

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi, we generally use blazemeter recorder to get a .jmx file so that we can import directly into JMeter. In case you get .yaml can convert here - converter.blazemeter.com/

  • @saurabhsrivastav902
    @saurabhsrivastav902 2 роки тому

    Hi Raghav, I have a placed Webdriver sampler inside an If-Controller which should run if ResponseCode is 401. But the sampler is automatically gets executed as soon as the thread group starts. Can you let me know how I can use Webdriver sampler inside an if-controller?

    • @RaghavPal
      @RaghavPal  2 роки тому

      Hi Saurabh, will need to check some examples online

    • @saurabhsrivastav902
      @saurabhsrivastav902 2 роки тому

      @@RaghavPal Hi Raghav, thanks for the reply. I got the issue. The webdriver sampler starts as soon as the threadgroup is triggered. But it executes only when condition is met.

    • @RaghavPal
      @RaghavPal  2 роки тому

      ok

  • @preetipretty9246
    @preetipretty9246 2 роки тому

    Hi Raghav,
    Could you please let me know if we can capture server side metrics if we use selenium scripts in Jmeter..

    • @RaghavPal
      @RaghavPal  2 роки тому

      It should, better will be For server side you can directly create a http sampler

  • @soulful2665
    @soulful2665 4 роки тому

    Hi Raghav, is there any way to load test on MS teams web app ? I'm finding difficult in Authentication as it uses oauth from azure AD

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Suhas, I am yet to work deeply on that, Pls try online examples

  • @thangarajs3961
    @thangarajs3961 4 роки тому

    Hi Raghav, is it possible measure the response time for each individual interactions like navigate url, login page, and landing of home page

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Thangaraj, You can do by calculating time, but the better option will be to use tools like JMeter. You can ask this in relevant video comments

  • @nishant585
    @nishant585 8 місяців тому

    I can't find plugin manager in Jmeter. can you please help me to add selenium webdriver support in Jmeter. you only show how to download that if you dont have plugin manager in Jmeter, but you didnt show how to set that selnium webdriver support inside Jmeter. I need your help

    • @RaghavPal
      @RaghavPal  8 місяців тому

      Nishant
      You're right, it seems there was a misunderstanding! Adding Selenium WebDriver support to JMeter without the Plugin Manager requires manual steps. Here's how you can do it:
      1. Download necessary libraries:
      - Download the appropriate WebDriver for your browser (e.g., chromedriver.exe for Chrome) from the corresponding official website.
      - Download the `selenium-client-api.jar` and `selenium-server-standalone.jar` libraries from the Maven Central Repository or manually from .
      2. Add libraries to JMeter classpath:
      - Copy the downloaded WebDriver executable and JAR files to a folder accessible by JMeter.
      - Open the JMeter installation directory (e.g., `C:\Program Files\Apache Software Foundation\Apache JMeter\bin`).
      - Open the `user.properties` file (may require creating it if it doesn't exist).
      - Add the following line to the file, replacing `` with the actual path to your libraries:
      classpath=\chromedriver.exe;\selenium-client-api.jar;\selenium-server-standalone.jar
      3. Create Test Plan and configure WebDriver Sampler:
      - In JMeter, create a new Test Plan and add a Thread Group.
      - Right-click on the Thread Group and select "Add -> Samplers -> WebDriver Sampler".
      - Configure the WebDriver Sampler:
      - Server Configuration: Select "Embedded Selenium Server" and provide the path to `selenium-server-standalone.jar`.
      - Browser & Capabilities: Choose your desired browser and configure any specific capabilities if needed.
      - Implementation: Select "Java - org.openqa.selenium.WebDriver".
      - Script (JavaScript / JSON): Enter your Selenium WebDriver script here.
      4. Run the test:
      - Save your Test Plan and start the test.
      Note: This approach requires manually maintaining the libraries and configuration every time. To streamline the process, consider installing the JMeter Plugins Manager through alternative methods and using the dedicated Selenium WebDriver plugin for simpler configuration and updates.
      Remember to replace `` with the actual path to your downloaded files and tailor the WebDriver Sampler configuration to your specific test requirements. If you encounter any issues, feel free to provide more details about your setup and error messages for further assistance.

  • @TheBharathibalaji
    @TheBharathibalaji 3 роки тому

    Hi sir,Shall we use webdriver sampler to execute javascript actions?

    • @RaghavPal
      @RaghavPal  3 роки тому

      Can try, also check some online examples

  • @eunicelok4882
    @eunicelok4882 4 роки тому

    Hi, want to ask, if Jmeter do not have JavaScript as the scripting language, which scripting language will you suggest to use ya? And let's say if we choose java, can we follow the same syntax for the scripts? Or do you know of any way to add JavaScript as one of the scripting language available?

    • @RaghavPal
      @RaghavPal  4 роки тому +1

      Hi Eunice, this can help stackoverflow.com/questions/42838448/how-to-use-javascript-executor-for-webdriver-sampler-in-jmeter

    • @eunicelok4882
      @eunicelok4882 4 роки тому

      @@RaghavPal thanks for the reply. But it isn't what I'm looking for. The JMeter that I've installed into the Mac OS does not come with JavaScript. There isn't much tutorial on using other language to write the tests scripts in web driver sampler. Can I ask, if i want to navigate between pages and want to record the load time, is there any other method to do it in JMeter?

    • @RaghavPal
      @RaghavPal  4 роки тому +1

      I will check on this and if I get time will create a session

    • @eunicelok4882
      @eunicelok4882 4 роки тому

      @@RaghavPal Thank you! :)

  • @pchandrarao3608
    @pchandrarao3608 3 роки тому

    Hi Raghav,
    Again Chandra Here.
    Added Selenium script to the Jmeter, but I was unable to manage "certificate" using the selenium script.
    Getting the "NET::ERR_CERT_AUTHORITY_INVALID" error.
    I tried to the following script but giving error for the following,
    ChromeOptions options = new ChromeOptions()
    chrome_options.add_argument('--allow-insecure-localhost')
    DesiredCapabilities caps = DesiredCapabilities.chrome()
    caps.setCapability(ChromeOptions.CAPABILITY, options)
    caps.setCapability("acceptInsecureCerts", true)
    WebDriver driver = new ChromeDriver(caps)
    How to modify as per the JMeter?
    Please help me.
    --Chandra

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Chandra, did you try to disable ssl validation in JMeter

  • @s1h2r345
    @s1h2r345 2 роки тому

    Hi Raghav, Thanks for this Video. I am looking for JMeter - Testing React Applications, can you please do share a Video on this.

    • @RaghavPal
      @RaghavPal  2 роки тому

      Will try, but can take sometime Sudheer, can try some online help on this

  • @ravikaruturi8742
    @ravikaruturi8742 4 роки тому

    Hi Raghav, thanks for the Informative session. I'm trying the same thing but facing an error saying "java.lang.IllegalArgumentException: Browser has not been configured. Please ensure at least 1 WebDriverConfig is created for a ThreadGroup." I have config chrome web driver under thread group, Is there anything that has to configured from browser side which I'm missing? Thanks for your help.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Ravi, did you download the browser driver and do the setup. Pls check stackoverflow.com/questions/56039878/jmeter-webdriver-can-not-load-web-page-on-chrome/56060425

    • @ravikaruturi8742
      @ravikaruturi8742 4 роки тому

      @@RaghavPal
      Hi Raghav thanks for your reply.. I have done the setup as described in the video. But finally worked in another machine but not in my local machine not sure what the root cause. Thanks for your reply

  • @pankajkukkar3849
    @pankajkukkar3849 4 роки тому

    Hi Raghav,
    This Jmeter training really helped me to learn Jmeter in 3 days. Thank for the nice tutorials.
    I was trying Jmeter with Selenium web driver and have a scenario where sampler1 saves a value in var A and then i execute one http sampler request and again run the webdriver sampler to get the latest values from the UI and compare if the new value is incremented by 1.
    But i am not getting how to pass the variable A from the webdriver sampler1 to webdriver sampler 2.
    Could you please help me on this?
    Thanks in advance.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Pankaj, you can store the values in user defined variables or properties in JMeter and refer in next step. You will find ways to do this with examples online. Having said this, JMeter may not be very good for client side performance analysis. But is very efficient for server side

  • @ahmedzaky6263
    @ahmedzaky6263 3 роки тому

    Hello Raghav , I faced an issue while using HTTPS scrirpt recorder on mobile App testing :Iam doing the following steps ; 1-add Https script recorder template 2-Install the certificate on mobile 3-add the Jmeter machine IP on the advanced settings 4-add the same port used on jmeter but I faced network unavailable and apps not working due to the network issue

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Ahmed, can be due to device specific settings, will need some online help

    • @ahmedzaky6263
      @ahmedzaky6263 3 роки тому

      @@RaghavPal are there any differences between Andriod 9 and the other ones ?

    • @RaghavPal
      @RaghavPal  3 роки тому

      Yes, there can be some changes

  • @deepthinivetha6143
    @deepthinivetha6143 5 років тому

    hi Raghav
    I tried with the above sample coding that u have provided, I was able to open the google page but i was notable to view any results in tree/table.Can you please help me with this.

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Deepthi, I hope you have added these statement
      WDS.sampleResult.sampleStart()
      WDS.sampleResult.sampleEnd()
      before and after the selenium scripts. Pls check and also see the logs for troubleshooting

  • @madhumanthri3207
    @madhumanthri3207 4 роки тому +1

    Using web driver sampler is it good to perform performance testing what are the other ways of doing

    • @RaghavPal
      @RaghavPal  4 роки тому +1

      Hi Madhu, JMeter generally checks the response time from server and does not take into consideration client render time. Using plugins like web driver sampler we can do some client end, but may not be very efficient client side test. There are some other ways for client side testing like ua-cam.com/video/XMFrNla8bHI/v-deo.html

    • @madhumanthri3207
      @madhumanthri3207 4 роки тому

      Hello i need some help in creating log in script using saml request and response if there any sample video can you please recommend

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Madhu, do you mean login test with JMeter, You will find in JMeter beginner playlist here - automationstepbystep.com/

  • @swastikpattnaik7117
    @swastikpattnaik7117 4 роки тому

    Hi Raghav, Thanks for this nice tutorial. I want to know that is it possible to use multiple webdriver samplers for different transactions in a single JMeter Thread Group. I tried that but got errors from the 2nd webdriver sampler onwards. Please explain it.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Swastik, what is the error. Can also check some examples online

  • @manchala2011
    @manchala2011 6 місяців тому

    Hi Ragav, what if the url redirect to some other login page like Azure login page? how do we capture that page here. My case i am giving server url for login then it redirects to Azure login page

    • @RaghavPal
      @RaghavPal  6 місяців тому

      Aravind
      When using JMeter to test a scenario where the URL redirects to another login page (such as the Azure login page), you can capture the redirection URL and handle it appropriately. Here's how you can achieve this:
      1. Disable Automatic Redirects:
      - By default, JMeter follows redirects automatically. To disable this behavior, uncheck the "Follow Redirects" option in your HTTP Request sampler.
      - This ensures that JMeter stops at the redirection response and does not automatically follow the redirect.
      2. Extract the Redirection URL:
      - When the server sends a redirection response (usually with a 302 status code), it includes a Location header indicating where the client should be redirected.
      - To extract this redirection URL, follow these steps:
      - Add a Regular Expression Extractor post-processor as a child of the main HTTP Request sampler.
      - Configure the Regular Expression Extractor as follows:
      - Apply to: Main sample and sub-samples
      - Field to check: Response headers
      - Reference Name: Choose a meaningful variable name (e.g., `location`)
      - Regular Expression: `Location: (.*)`
      - Template: `$1`
      - This will extract the redirection URL from the Location header and store it in the `${location}` variable.
      3. Use the Extracted Variable:
      - You can now use the extracted URL in subsequent requests.
      - For example, if you need to follow the redirection to the Azure login page, include an additional HTTP Request sampler after the initial request.
      - In the new sampler, set the Server Name or IP to `${location}` (the extracted URL).
      4. Verify the Behavior:
      - Run your test plan and verify that JMeter captures the redirection URL correctly.
      - Inspect the results to ensure that the redirection to the Azure login page occurs as expected.
      Remember that handling redirections in JMeter involves stopping at the redirection response, extracting the relevant information, and manually following the redirection in subsequent requests. By using the Regular Expression Extractor, you can capture the redirection URL dynamically and adapt your test plan accordingly

  • @nehachoudhari7462
    @nehachoudhari7462 4 роки тому

    Hi Ragav.can i config jmeter with jenkins using webdriver sampler

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Neha, you can. In simple words if you can run a test from command line, you can integrate with Jenkins

  • @manshap400
    @manshap400 4 роки тому

    Hi Raghav, Is it possible to do performance testing of Service now application using Jmeter?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Mansha, what is service now, I will need more details

  • @mayi8883
    @mayi8883 2 роки тому

    Is there a way to use controller for UI scenario to calculate the time it take each page to load . For example : one controller for the steps in the home page , then another for the welcome page

    • @RaghavPal
      @RaghavPal  2 роки тому

      I have not used it Mayi, can try to take some online help

  • @prashantmahajantanashah
    @prashantmahajantanashah Рік тому

    Hi raghav, Thanks for wonderful video. my browser opeens ad suddenly closes. I dowloaded the same chromedriver as per my browser version.Still the issue persists
    please help

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Prashant, Try to use the -Dwebdriver.chrome.silentOutput=true JVM argument to avoid unnecessary output, by adding it to the jmeter.bat file if you're running on windows or to the jmeter script file if you're running on other OS
      OR
      Try to run the test with a headless browser, it can be done by adding -Dwebdriver.chrome.args=--headless JVM argument

  • @indiansweets
    @indiansweets 4 роки тому

    Hi Raghav, how to create hawk request in Jmeter. Do we have any available plugin for it.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Vineet, I will have to check online for this.

  • @mihirsoni9888
    @mihirsoni9888 2 роки тому

    When i use web driver sampler in jmeter i dont get javascript in language.
    Can you please explain the process or any configuration how to enable javascript.

    • @RaghavPal
      @RaghavPal  2 роки тому

      Hi Mihir, hope you have added all the required plugins as shown, try again, also check the latest docs online

  • @aishwaryaaravind9013
    @aishwaryaaravind9013 4 роки тому +1

    Thank you sir for your tutorial. Can you please help me regarding the below error JMeter v 5.3 integration with selenium
    - Followed your videos & trying the same steps.
    - chromedriver 84, 85 in sync with Chrome browser version.
    2020-08-25 20:35:26,269 ERROR o.a.j.t.JMeterThread: Error while processing sampler: 'jp@gc - WebDriver Sampler'.
    java.lang.IllegalArgumentException: Browser has not been configured. Please ensure at least 1 WebDriverConfig is created for a ThreadGroup

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Aishwarya, this will help
      stackoverflow.com/questions/56039878/jmeter-webdriver-can-not-load-web-page-on-chrome

    • @aishwaryaaravind9013
      @aishwaryaaravind9013 4 роки тому

      @@RaghavPal Thank you sir. Working now.
      Thank you for posting the Postman and Selenium playlists. Really helpful for understanding from the basics.

  • @saikrishna5893
    @saikrishna5893 3 роки тому

    How can we divide tests. Like I want to know how much time does it take for hitting Search button.
    Response time for
    1. Loading of www.google.com
    2. Enter text and hit Search
    How to differentiate this?

    • @RaghavPal
      @RaghavPal  3 роки тому

      Can try module controller

  • @truptisagarikasahoo3528
    @truptisagarikasahoo3528 4 роки тому +1

    Hi Raghav, could you please share how to use sub samplers in webdriver sampler

  • @henriettabalzam8726
    @henriettabalzam8726 4 роки тому

    Thank you for the tutorial, it is very helpful. I am planing a load test with four webdriver samplers, but I have a problem. The first sampler is for login process and the second one for some process after login. Could you help me, is it possible to stay logged in after the first process?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Henrietta, You may have to pass the token or session id. This may help
      stackoverflow.com/questions/34608368/jmeter-webdriver-sampler-how-to-save-token-from-auhtorization-cookie

  • @haripriyasatrasala4027
    @haripriyasatrasala4027 3 роки тому

    Hello, Raghav. I am unable to find the javascript option in selenium web driver. I have tried using different versions but found no luck. Please help me how can I write selenium in javascript

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Satrasala, I will check if this can be due to diff ver of JMeter. Meanwhile pls also check online

    • @BALJOTSINGH
      @BALJOTSINGH 3 роки тому

      Hi Install Jdk 12 version there you find javascript.

  • @BALJOTSINGH
    @BALJOTSINGH 4 роки тому

    Hi Raghav, thanks for details. I have one question on my windows laptop I can see javascript as script language under webdriver sampler, but on Mac its not available. Any reason why?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Baljot, i believe this should not be dependent on OS, just check if you are used the plugins, libraries required on mac

    • @BALJOTSINGH
      @BALJOTSINGH 4 роки тому

      @@RaghavPal Thanks for your reply , I added the same required plugins and I see this strange behaviour on Mac.

    • @BALJOTSINGH
      @BALJOTSINGH 4 роки тому

      Hi Raghav, I found out that when JDK 15 is installed I don't see JavaScript option, but when I install jdk 12, I can see Javascript option.

    • @RaghavPal
      @RaghavPal  4 роки тому

      Ok

  • @gauravkumar9909
    @gauravkumar9909 2 роки тому

    Hi Raghav, can you please provide the code snippet for right click and drag and drop. Selenium code is working in eclipse but when I am using same code in webdriver sampler then it is not working. I don’t know what modifications are required. Please help

    • @RaghavPal
      @RaghavPal  2 роки тому +2

      Hi Gaurav, I will add these

    • @gauravkumar9909
      @gauravkumar9909 2 роки тому

      @@RaghavPal Thanks

    • @gkvlogs21
      @gkvlogs21 Рік тому

      @@RaghavPal Hi Raghav, have you get time to see this functionality. I see minor minor issues while implementation but did not succeed. Pls help for this right click n drag and drop

  • @AdityaGUPTA-te1ld
    @AdityaGUPTA-te1ld Рік тому

    Hi im facing an issue in the script upon running the test, getting error below:
    javax.script.ScriptException: TypeError: Cannot read property "sendKeys" from undefined in at line number 5

    • @AdityaGUPTA-te1ld
      @AdityaGUPTA-te1ld Рік тому

      any solution for this ?

    • @RaghavPal
      @RaghavPal  Рік тому

      looks like some syntax error, Try to check some online examples

  • @dishatiwari4994
    @dishatiwari4994 4 роки тому

    Hi Raghav!
    I'm following the same steps which you have mentioned in the above video.......but when we search for chromedriver.exe, the downloadable file is only available for Win32.
    When I'm using the same Jmeter is not supporting it.
    Log: org.openqa.selenium.SessionNotCreatedException: session not created: This version of ChromeDriver only supports Chrome version 84
    Build info: version: '------', revision: 'aacccce0', time: '--------'
    System info: host: 'Hostname', ip: 'IPAddress', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '------------'
    Driver info: driver.version: ChromeDriver

    • @RaghavPal
      @RaghavPal  4 роки тому +1

      Hi Disha, the bit size is okay, 32 bit will work, its the version that it's complaining, When you goto chromedriver.chromium.org/downloads you can select the version. Most probably the latest ver or the ver as per the Chrome Browser on your system should work.
      Try and let me know if this works

    • @dishatiwari4994
      @dishatiwari4994 4 роки тому

      @@RaghavPal Hi Raghav!
      The solution Worked, Thanks A lot........... Your video literally made my job easy.

  • @amankaushal1010
    @amankaushal1010 5 років тому

    Hi..what about thick client ? If we want to measure performance of desktop based application (JNLP) from client side perspective (like rendering time etc.)..how can we achieve that ?

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Aman, you can use it. Can get some help here - ua-cam.com/video/8jqFKPHEZZE/v-deo.html

  • @mohsenbou
    @mohsenbou Рік тому

    thanks for your learning, but Javascript is not supported on Jmeter. It's replaced by Groovy.

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Mohsen
      JavaScript is supported in JMeter, but it is not the default language for scripting. The default scripting language for JMeter is Apache Groovy.
      However, you can still use JavaScript for scripting in JMeter by using the JSR223 Sampler. The JSR223 Sampler allows you to use any scripting language that is supported by the Java Scripting API, including JavaScript.
      To use JavaScript in JMeter, you need to select the JSR223 Sampler, choose the language as "javascript", and then enter your JavaScript code in the Script area.
      Here's an example of how to use JavaScript in a JSR223 Sampler in JMeter:
      Add a JSR223 Sampler to your Test Plan.
      Choose "javascript" as the language.
      Enter your JavaScript code in the Script area.
      For example, if you want to print "Hello, World!" to the JMeter console, you can use the following JavaScript code:
      print("Hello, World!");
      Note that the syntax for JavaScript in JMeter may be slightly different from the syntax you would use in a browser or other JavaScript environment. You may need to refer to the JMeter documentation or examples to ensure your JavaScript code is written correctly for use in JMeter

  • @mohbubulkarim5680
    @mohbubulkarim5680 5 років тому

    I have 2 questions:
    I was able to develop selenium scripts and then export as jar file and then import in Jmeter.
    The whole flow worked but that's for only one request/user. if I wanna run concurrently for multiple requests/users it will return me duplicate/failed.
    My first question is where and how should I create dynamic variable to avoid that problem and make sure that variable read the data from csv file?
    My 2nd question is Jmeter right tool to record the UI of single page application for performance testing? it seems like not but please answer with enough details

    • @RaghavPal
      @RaghavPal  5 років тому +1

      Hi Rana, in case you want to read from excel/csv file, there is a video on that in the series, pls check. Also there are functions for generating random strings in JMeter.
      JMeter is not for UI or in that matter any client. It is for server side performance analysis.

    • @mohbubulkarim5680
      @mohbubulkarim5680 5 років тому

      @@RaghavPal thanks for the reply but the problem is when I exported the selenium code to Jmeter as jar file I am only capable of selecting the package.class and then select the test name.
      if I put the load for 1000 users it will only pass for 1st user and the rest 999 requests will be duplicate/failed.
      The real question is after importing selenium code as jar file in Jmeter is there a way I can modify to parameterize some fields?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Rana, I believe this will not be the best way to test on JMeter. JMeter is anyways a server end performance testing tool, so It might not work directly for selenium scripts. I have a video on how to use selenium webdriver with JMeter although that too has some limitations. I will suggest you use JMeter for checking response time from server and not client performance

  • @kumudgoel6520
    @kumudgoel6520 3 роки тому

    I have got an issue--- Browser is opening but google.com is not launching and results also not captured WHY?

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Kumud, it can be due to version incompatibility between Se and browser, Try diff ver

  • @MrSachp
    @MrSachp 2 роки тому

    Hi Raghav. Thank you for this video. It was very helpful. How can you correlate dynamic values using this method? When I record the steps for login, there is a dynamic value as part of the login URL, which fails upon replay. Any ideas?

    • @RaghavPal
      @RaghavPal  2 роки тому

      Hi Sachin, you will need to store value in variable and refer with the variable name. Can check some examples online

    • @vijethaag6771
      @vijethaag6771 2 роки тому

      @@RaghavPal please share some doc regarding this

  • @vibhavaripatil86
    @vibhavaripatil86 Рік тому

    Nice video...But how do I parameterize link or username password in webdriver sampler, if I want to run the script on other server machine??

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Vibha, although using a plugin we are able to use selenium scripts in JMeter, but this may not be a very clean and scalable approach,
      In case you are interested should also watch how we use Gatling for this. Can get the videos here - automationstepbystep.com/

  • @anupamaprabhu9819
    @anupamaprabhu9819 4 роки тому

    Could you please provide more details on reporting aspect ? What kind of stats are evaluated when we test load at client end ?

    • @RaghavPal
      @RaghavPal  4 роки тому

      I will plan a session on this

  • @eduardovargas741
    @eduardovargas741 3 роки тому

    - Se observa que realizas el ejemplo en una maquina Mac pero al momento de realizarla cambias a Windows.
    - Esta mismo ejercicio se puede hacer en Mac?

    • @RaghavPal
      @RaghavPal  3 роки тому +1

      Sí, se puede hacer en mac

    • @eduardovargas741
      @eduardovargas741 3 роки тому

      @@RaghavPal Bien, Me puedes ayudar a saber como se hace?

    • @eduardovargas741
      @eduardovargas741 3 роки тому

      @@RaghavPal Hay algun manual donde pueda estudiar, te agradezco, muchas gracias. Saludos desde México Abrazos.

    • @RaghavPal
      @RaghavPal  3 роки тому

      Aún no tienes un tutorial. Necesitará buscar en línea por ahora

    • @eduardovargas741
      @eduardovargas741 3 роки тому

      @@RaghavPal Ya pude realizarlo en Mac con JMeter y Python, Gracias. Saludos desde Mexico

  • @GaneshMoorthiN
    @GaneshMoorthiN Рік тому

    Thanks for video, why the Latency ,connect time, send bytes are zero.

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Ganesh, It may be a very small test to capture all the metric or may be some issue, I will have to revisit and check

    • @GaneshMoorthiN
      @GaneshMoorthiN Рік тому

      @@RaghavPal sure thanks. looking forward

  • @saurabhsrivastav902
    @saurabhsrivastav902 2 роки тому

    Hi Raghav, thanks for the video. Can you plz let me know why it is not working in Jenkins. When I try to execute the WebDriverSampler In Jmeter(headless mode) through Jenkins, it says that Chrome driver started successfully and exits the script immediately. "org.openqa.selenium.remote.ProtocolHandshake CreateSession" doesn't executes in Jenkins(using the Build in -Windows command prompt). The script works fine in local system command prompt. Plz let me know what else can I configure in Jenkins to make it work?

    • @saurabhsrivastav902
      @saurabhsrivastav902 2 роки тому

      Hi Raghav, can you help me with the same webdriver execution through Jenkins. It doesn't work in Jenkins

    • @RaghavPal
      @RaghavPal  2 роки тому +1

      Hi Saurabh, will need to check the details and logs

  • @ravisinghrajpoot3086
    @ravisinghrajpoot3086 4 роки тому

    Hi Raghav
    Selenium/we driver support in jmeter is showing error "failed to apply changes : failed to download library selenium firefox driver"
    I am using : JMeter version 4.0
    Java version as 1.8.0
    Eclipse version Mars.1 Release 4.5.1
    Beside this I have also download jpgc-webdriver 3.1 n pasted the the jar file in lib-ext
    Still when I try to look for jp@gc.chrome driver config n others under config element it's not appearing there
    Please suggest what to do what I m missing

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Ravi, can you recheck with the video if any step is missed, Hope you restarted JMeter after adding libraries.

    • @ravisinghrajpoot3086
      @ravisinghrajpoot3086 4 роки тому

      @@RaghavPal Hi Raghav thanks much for writing back yes I hv restarted the jmeter n my system as well but the result is same 1 thing I missed to mention earlier that my company revoked firefox from everyone system could that be a problem ... Again thanks much for all ur support ur videos are really very helpful I hv learnt alot successfully wrote a script n parameterized the same ...

    • @RaghavPal
      @RaghavPal  4 роки тому

      That may be the reason you can try with Chrome Driver

  • @kranthikoura411
    @kranthikoura411 5 років тому

    Hi Ragav...............I followed steps correctly but when I click on button ..Its not running and also not getting any error......plz guide me

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Kranthi, pls check the logs

  • @gurneetkaur2146
    @gurneetkaur2146 4 роки тому

    Thanks for the Tutorial
    I ardently followed the steps starting from installing jmeter to adding the latest chrome driver, but for some reason my chrome browser launches, unfortunately does not populate the url and fails with an error.
    Java version : 1.8.0_261
    Jmeter : Latest
    Chrome driver : ChromeDriver 86.0.4240.22 for Chrome :: Version 86.0.4240.75
    STACK TRACE::
    2020-10-14 14:43:04,878 INFO o.j.r.JARSourceHTTP: Found cached repo
    2020-10-14 14:43:05,091 INFO o.j.r.PluginManager: Plugins Status: [jpgc-plugins-manager=1.4, jpgc-webdriver=3.3, jmeter-core=5.3, jmeter-ftp=5.3, jmeter-http=5.3, jmeter-jdbc=5.3, jmeter-jms=5.3, jmeter-junit=5.3, jmeter-java=5.3, jmeter-ldap=5.3, jmeter-mail=5.3, jmeter-mongodb=5.3, jmeter-native=5.3, jmeter-tcp=5.3, jmeter-components=5.3]
    2020-10-14 14:44:36,458 INFO o.a.j.s.SampleResult: Note: Sample TimeStamps are START times
    2020-10-14 14:44:36,459 INFO o.a.j.s.SampleResult: sampleresult.default.encoding is set to ISO-8859-1
    2020-10-14 14:44:36,459 INFO o.a.j.s.SampleResult: sampleresult.useNanoTime=true
    2020-10-14 14:44:36,459 INFO o.a.j.s.SampleResult: sampleresult.nanoThreadSleep=5000
    2020-10-14 14:48:03,791 INFO o.a.j.s.FileServer: Default base='C:\MyFolder\WORK\Tools\JMeter\apache-jmeter-5.3\bin'
    2020-10-14 14:48:03,792 INFO o.a.j.s.FileServer: Set new base='C:\MyFolder\WORK\Tools\JMeter\apache-jmeter-5.3\bin'
    2020-10-14 14:48:03,982 INFO o.a.j.s.SaveService: Testplan (JMX) version: 2.2. Testlog (JTL) version: 2.2
    2020-10-14 14:48:03,998 INFO o.a.j.s.SaveService: Using SaveService properties file encoding UTF-8
    2020-10-14 14:48:04,001 INFO o.a.j.s.SaveService: Using SaveService properties version 5.0
    2020-10-14 14:48:06,251 INFO o.a.j.e.StandardJMeterEngine: Running the test!
    2020-10-14 14:48:06,253 INFO o.a.j.s.SampleEvent: List of sample_variables: []
    2020-10-14 14:48:06,253 INFO o.a.j.s.SampleEvent: List of sample_variables: []
    2020-10-14 14:48:06,256 INFO o.a.j.e.u.CompoundVariable: Note: Function class names must contain the string: '.functions.'
    2020-10-14 14:48:06,256 INFO o.a.j.e.u.CompoundVariable: Note: Function class names must not contain the string: '.gui.'
    2020-10-14 14:48:06,740 INFO o.a.j.g.u.JMeterMenuBar: setRunning(true, *local*)
    2020-10-14 14:48:06,959 INFO o.a.j.e.StandardJMeterEngine: Starting ThreadGroup: 1 : Thread Group
    2020-10-14 14:48:06,959 INFO o.a.j.e.StandardJMeterEngine: Starting 1 threads for group Thread Group.
    2020-10-14 14:48:06,959 INFO o.a.j.e.StandardJMeterEngine: Thread will continue on error
    2020-10-14 14:48:06,960 INFO o.a.j.t.ThreadGroup: Starting thread group... number=1 threads=1 ramp-up=1 delayedStart=false
    2020-10-14 14:48:06,974 INFO o.a.j.t.ThreadGroup: Started thread group number 1
    2020-10-14 14:48:06,974 INFO o.a.j.e.StandardJMeterEngine: All thread groups have been started
    2020-10-14 14:48:06,976 INFO o.a.j.t.JMeterThread: Thread started: Thread Group 1-1
    2020-10-14 14:49:09,314 ERROR o.a.j.t.JMeterThread: Error calling threadStarted
    org.openqa.selenium.WebDriverException: chrome not reachable
    Build info: version: '3.14.0', revision: 'aacccce0', time: '2018-08-02T20:19:58.91Z'
    System info: host: ' ', ip: ' ', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_261'
    Driver info: driver.version: ChromeDriver
    remote stacktrace: Backtrace:
    Ordinal0 [0x0055C013+3194899]
    Ordinal0 [0x00446021+2056225]
    Ordinal0 [0x002DF4B0+586928]
    Ordinal0 [0x002D57C5+546757]
    Ordinal0 [0x002616F0+71408]
    Ordinal0 [0x0025E229+57897]
    Ordinal0 [0x0025C64A+50762]
    Ordinal0 [0x00281EE9+204521]
    Ordinal0 [0x00281D0D+204045]
    Ordinal0 [0x0027FC1B+195611]
    Ordinal0 [0x00263B7F+80767]
    Ordinal0 [0x00264B4E+84814]
    Ordinal0 [0x00264AD9+84697]
    Ordinal0 [0x0045CE64+2149988]
    GetHandleVerifier [0x006CBE95+1400773]
    GetHandleVerifier [0x006CBB61+1399953]
    GetHandleVerifier [0x006D31FA+1430314]
    GetHandleVerifier [0x006CC69F+1402831]
    Ordinal0 [0x00453D61+2112865]
    Ordinal0 [0x0045E5CB+2155979]
    Ordinal0 [0x0045E6F5+2156277]
    Ordinal0 [0x0046F26E+2224750]
    BaseThreadInitThunk [0x75676359+25]
    RtlGetAppContainerNamedObjectPath [0x77177C24+228]
    RtlGetAppContainerNamedObjectPath [0x77177BF4+180]
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:1.8.0_261]
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) ~[?:1.8.0_261]
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) ~[?:1.8.0_261]
    at java.lang.reflect.Constructor.newInstance(Unknown Source) ~[?:1.8.0_261]
    at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$new$0(W3CHandshakeResponse.java:57) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$getResponseFunction$2(W3CHandshakeResponse.java:104) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.ProtocolHandshake.lambda$createSession$0(ProtocolHandshake.java:122) ~[selenium-remote-driver-3.14.0.jar:?]
    at java.util.stream.ReferencePipeline$3$1.accept(Unknown Source) ~[?:1.8.0_261]
    at java.util.Spliterators$ArraySpliterator.tryAdvance(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.ReferencePipeline.forEachWithCancel(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.AbstractPipeline.copyIntoWithCancel(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.AbstractPipeline.copyInto(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.FindOps$FindOp.evaluateSequential(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.AbstractPipeline.evaluate(Unknown Source) ~[?:1.8.0_261]
    at java.util.stream.ReferencePipeline.findFirst(Unknown Source) ~[?:1.8.0_261]
    at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:125) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:73) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:136) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:83) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:548) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:212) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:130) ~[selenium-remote-driver-3.14.0.jar:?]
    at org.openqa.selenium.chrome.ChromeDriver.(ChromeDriver.java:181) ~[selenium-chrome-driver-3.14.0.jar:?]
    at com.googlecode.jmeter.plugins.webdriver.config.ChromeDriverConfig.createBrowser(ChromeDriverConfig.java:83) ~[jmeter-plugins-webdriver-3.3.jar:?]
    at com.googlecode.jmeter.plugins.webdriver.config.ChromeDriverConfig.createBrowser(ChromeDriverConfig.java:21) ~[jmeter-plugins-webdriver-3.3.jar:?]
    at com.googlecode.jmeter.plugins.webdriver.config.WebDriverConfig.getPreparedBrowser(WebDriverConfig.java:234) ~[jmeter-plugins-webdriver-3.3.jar:?]
    at com.googlecode.jmeter.plugins.webdriver.config.WebDriverConfig.threadStarted(WebDriverConfig.java:221) ~[jmeter-plugins-webdriver-3.3.jar:?]
    at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:769) [ApacheJMeter_core.jar:5.3]
    at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:993) [jorphan.jar:5.3]
    at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:976) [jorphan.jar:5.3]
    at org.apache.jmeter.threads.JMeterThread.threadStarted(JMeterThread.java:737) [ApacheJMeter_core.jar:5.3]
    at org.apache.jmeter.threads.JMeterThread.initRun(JMeterThread.java:725) [ApacheJMeter_core.jar:5.3]
    at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:252) [ApacheJMeter_core.jar:5.3]
    at java.lang.Thread.run(Unknown Source) [?:1.8.0_261]
    2020-10-14 14:49:09,326 ERROR o.a.j.t.JMeterThread: Error while processing sampler: 'jp@gc - WebDriver Sampler'.
    java.lang.IllegalArgumentException: Browser has not been configured. Please ensure at least 1 WebDriverConfig is created for a ThreadGroup.
    at com.googlecode.jmeter.plugins.webdriver.sampler.WebDriverSampler.sample(WebDriverSampler.java:62) ~[jmeter-plugins-webdriver-3.3.jar:?]
    at org.apache.jmeter.threads.JMeterThread.doSampling(JMeterThread.java:630) ~[ApacheJMeter_core.jar:5.3]
    at org.apache.jmeter.threads.JMeterThread.executeSamplePackage(JMeterThread.java:558) ~[ApacheJMeter_core.jar:5.3]
    at org.apache.jmeter.threads.JMeterThread.processSampler(JMeterThread.java:489) [ApacheJMeter_core.jar:5.3]
    at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:256) [ApacheJMeter_core.jar:5.3]
    at java.lang.Thread.run(Unknown Source) [?:1.8.0_261]
    2020-10-14 14:49:09,327 INFO o.a.j.t.JMeterThread: Thread is done: Thread Group 1-1
    2020-10-14 14:49:09,327 INFO o.a.j.t.JMeterThread: Thread finished: Thread Group 1-1
    2020-10-14 14:49:09,845 INFO o.a.j.e.StandardJMeterEngine: Notifying test listeners of end of test
    2020-10-14 14:49:09,845 INFO o.a.j.g.u.JMeterMenuBar: setRunning(false, *local*)
    Any Help is appreciated...

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Gurneet, pls check if version of chrome browser on the system and chromedriver.exe ver matches. Also check compatibility with Selenium ver

  • @Unnameddde2
    @Unnameddde2 Рік тому

    my button in the company dont have id and name. Just have class. How do the clic?

    • @RaghavPal
      @RaghavPal  Рік тому

      can use class property to create locator

  • @aseelmasad2723
    @aseelmasad2723 2 роки тому

    if i have a selenuim maven project , how can i add the project to jmeter , all the jars added to the POM in eclipse

    • @RaghavPal
      @RaghavPal  2 роки тому

      I don't think that will be an efficient way Aseel

  • @nilaycontractor6670
    @nilaycontractor6670 5 років тому

    Hi,
    I applied the same script as shown in video and notice that script executing is too faster.
    so my question is 'How to put wait between each step?'
    please give me reply as soon as possible. because i am stuck

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Nilay, sorry for late reply. Have you checked here - stackoverflow.com/questions/53958524/wait-time-issue-in-jmeter-webdriver-sampler

  • @noblebenny4050
    @noblebenny4050 3 роки тому

    I tried to do the same with j meter and selenium but chrome is popped up and closing immedietly .why so?

    • @RaghavPal
      @RaghavPal  3 роки тому

      Will need to check the logs. It may be due to the ver of chrome on your system and chromedriver.exe not matching

  • @harshasri556
    @harshasri556 3 роки тому

    By using Webdriver scripts can we get the response times of individual clicks being made on an application

    • @RaghavPal
      @RaghavPal  3 роки тому

      Hi Sri, it will be tricky and not scalable for a large user load

    • @harshasri556
      @harshasri556 3 роки тому

      @@RaghavPal Can we do it at least for single user.If so can you provide any sample scripts

    • @RaghavPal
      @RaghavPal  3 роки тому

      will check more on this

  • @cibelless510
    @cibelless510 4 роки тому

    Thanks my friend for this video. I have one question, how to run wit headless browser? Is it possible? Thanks

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Vinicius, You can use headless mode or Firefox and Chrome and have the scripts for that. I am yet to work on that, For now, can check online

  • @MariusTablet
    @MariusTablet Рік тому

    Hi. Is there a way to open the chrome browser or edge browser in incognito mode? if yes, could you please show this? Thanks

    • @RaghavPal
      @RaghavPal  Рік тому

      Hi Marius
      There is a way, Before providing details, I will suggest, using Se webdriver with JMeter may not be very efficient for a heavy load test
      If you like to continue, To do this, you need to add the following configuration to your JMeter script:
      ```
      chromeOptions = new ChromeOptions();
      chromeOptions.addArguments("--incognito");
      ```
      This will tell the Chrome browser to open in incognito mode. You can also use the same configuration for the Edge browser.
      Here is an example of how to use the configuration in your JMeter script:
      ```
      import org.openqa.selenium.chrome.ChromeDriver;
      import org.openqa.selenium.chrome.ChromeOptions;
      public class IncognitoModeTest {
      public static void main(String[] args) {
      // Create a new ChromeOptions object.
      ChromeOptions chromeOptions = new ChromeOptions();
      // Add the incognito mode argument.
      chromeOptions.addArguments("--incognito");
      // Create a new ChromeDriver object.
      ChromeDriver driver = new ChromeDriver(chromeOptions);
      // Open a web page.
      driver.get("www.google.com");
      // Close the browser.
      driver.quit();
      }
      }
      ```
      This code will open the Chrome browser in incognito mode and open the Google homepage. The browser will then be closed.
      To run the code, you can save it as a JMeter script and then run it from the JMeter GUI.

    • @MariusTablet
      @MariusTablet Рік тому

      Hi. I managed to find a solution without writing that code that you recommended below. Just add "--incognito" to Edge browser config plugin in jmeter and it will work without issues.

  • @rajkumardas9048
    @rajkumardas9048 2 роки тому

    Great explanation!! Thank you for this video

  • @piyushraj27
    @piyushraj27 4 роки тому

    Hello Sir..after installing Katalon the same window is not opened..i.e in this video 10 minute 30 seconds...m trying last 45 minutes but its not showing the same window...i done something wrong OR i have to open from somewhere else...Please Help me

    • @RaghavPal
      @RaghavPal  4 роки тому +1

      Hi Piyush, what exactly you mean by same window, Once you install Katalon recorder plugin, you will find it added on chrome and then click on the icon, it opens katalon recorder window where you can record your steps.

    • @piyushraj27
      @piyushraj27 4 роки тому

      @@RaghavPal Sir my question after installing Katalon...till there i done it...after that according to your videos...i.e 10 minute 30 seconds...directly it comes to Test suites window...(This only m not getting...)from where i have to go Test Suites pages...

    • @piyushraj27
      @piyushraj27 4 роки тому

      thanku so much sir...i got it..I have just started from a very basic understanding and quickly adapts the level , Fantastic so far, would recommend to anyone....

  • @letuslearnscience-piyushku284
    @letuslearnscience-piyushku284 5 років тому

    Hi Raghav, It is a very nice explanation. How to export Selenium Scripts from Eclipse and execute through Jmeter. Pl help me out. Many thanks

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Peeyush, You may not be able to use it directly. Can take some help from stackoverflow.com/questions/7817498/running-selenium-scripts-with-jmeter

    • @letuslearnscience-piyushku284
      @letuslearnscience-piyushku284 5 років тому +1

      @@RaghavPal : Thank you Raghav for your time.

  • @amandahaydaw9053
    @amandahaydaw9053 4 роки тому

    Thanks for your video.
    I want to use firefox config , I am having an issue to set firefox binary path
    Do u have any tutorial using firefox webdriver?
    Thanks,

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Amanda, I have a playlist on Selenium. Pls check here - automationstepbystep.com/online-courses/

  • @nehajain9388
    @nehajain9388 10 місяців тому

    Sir could you please let us know the version of Google Chrome bcz my code throw illegal exception web driver not config

    • @RaghavPal
      @RaghavPal  10 місяців тому

      Neha, as of now I do not remember it. You can check online for the compatible versions

  • @testemis6911
    @testemis6911 4 роки тому

    Hi Raghav, nice explanation, but while automating gmail with jmeter I can able to enter username but I can't enter password as it is in the next page and I am getting this error " element is not attached to the page document" can you please tell me what is the solution for this or how to wait for the element to load as I failed using implicit ad explicit waits.
    Thanks in advance

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi, this error comes in UI Automation when element is not present in the DOM of the web page.
      JMeter might not be able to handle such issues efficiently as it is not a client side testing tool.

  • @nehasabharwals
    @nehasabharwals 4 роки тому

    Hi Raghav,
    When I run multiple samplers consecutively, then it throws invalid session ID error.
    Could you please help me with this?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Neha, will have to check your requests, setup and logs for this

    • @nehasabharwals
      @nehasabharwals 4 роки тому

      OK... So, how do I share this with you?

    • @RaghavPal
      @RaghavPal  4 роки тому

      You can send me an email with details (raghav.qna@gmail.com), But replies on email are much delayed

  • @rutulshah2007
    @rutulshah2007 4 роки тому

    How can I add assertions in the script you explained ? Can we use xpath assertions?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Rutul, You can add a listener view results tree and check the response, If you are getting the response in jmeter you can add assertions else it will not work

  • @waniya-huzzu
    @waniya-huzzu 4 роки тому

    Hi Raghav, can't we Java instead of Javascript?

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi Azhar, not sure if support for that is there, will need to check online

  • @barunadhikari8782
    @barunadhikari8782 4 роки тому

    Thanks alot , Can i ask if it is possible to run selenium python seperately and get the results in jmeter ?

    • @RaghavPal
      @RaghavPal  4 роки тому

      You may try using the proxy server, but I will need to check how accurately and efficiently that can work,

    • @barunadhikari8782
      @barunadhikari8782 4 роки тому

      @@RaghavPal Thanks brother for the reply. And do you have like discord server where i can interact with people learning the same stuff as me.

    • @RaghavPal
      @RaghavPal  4 роки тому

      No Barun

  • @smphub8886
    @smphub8886 4 роки тому

    Hi Raghav,
    First of all Thanks a lot for such a good tutorial.
    While executing scripts, I am facing below exception.
    Response code:500
    Response message:Cannot cast jdk.nashorn.internal.runtime.Undefined to org.openqa.selenium.By
    Can you please help me with this? I am using javascript

    • @RaghavPal
      @RaghavPal  4 роки тому

      Hi, I beleive some issue in the setup. Can you show me your code and do recheck the other setup lib

  • @tejastoley6714
    @tejastoley6714 5 років тому

    i have plugins under option but i do not have any option to add webdriver plugin,i can see the version documentation.

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Tejas, the button to add is at the bottom of the window. Sometimes due to window size it is not visible. Pls check. In case it is already added, you will find it in the Installed tab.

  • @sharanbasava7632
    @sharanbasava7632 4 роки тому

    Hi Raghav, what about the webdriver sampler report..how to analyze the report..
    pls explain on how to analyze graphical report. ThankYou..

    • @RaghavPal
      @RaghavPal  4 роки тому

      I will have to check and do a session on this Sharan

    • @sharanbasava7632
      @sharanbasava7632 4 роки тому

      @@RaghavPal ThankYou raghav..

  • @bhushanshet7329
    @bhushanshet7329 5 років тому

    I am running jmeter test case using single thread using chrome driver, test doesn't end and when I try to click stop I get this message " Shutting down all test threads. You can see number of active threads in the upper right corner of GUI. Please be patient"

    • @RaghavPal
      @RaghavPal  5 років тому

      Hi Bhushan, will have to see your setup or logs to check this

    • @bhushanshet7329
      @bhushanshet7329 5 років тому +1

      @@RaghavPal Thanks for replying. I figured it out that few jar files wer missing from Lib folder.