Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Performance	
  Tes-ng	
  with	
  Real	
  Browsers	
  
Harnessing	
  the	
  power	
  of	
  JMeter	
  &	
  Selenium	
  Webdr...
AGENDA	
  
•  JMeter	
  vs	
  Real	
  Browsers	
  
•  Installing	
  the	
  JMeter	
  Webdriver	
  Plugin	
  
•  CreaCng	
 ...
About	
  BlazeMeter	
  
API	
  |	
  Mobile	
  |	
  Web	
  |	
  CI	
  |	
  Load	
  &	
  Performance	
  TesCng	
  |	
  Cloud...
JMeter	
  vs	
  Real	
  Browsers	
  
Real	
  Browsers	
  
•  AcCvity	
  defined	
  in	
  terms	
  of	
  user	
  acCons	
  
...
JMeter	
  vs	
  Real	
  Browsers	
  
JMeter	
  
•  AcCvity	
  defined	
  in	
  terms	
  of	
  HTTP	
  acCons	
  
–  HTTP	
 ...
Resource	
  Requirements	
  
JMeter	
  vs	
  Real	
  Browsers	
  
JMeter	
   Real	
  Browsers	
  
300	
  to	
  2000	
  vir...
Installing	
  JMeter	
  Webdriver	
  Plugin	
  
•  Download	
  Zip	
  from	
  jmeter-­‐plugins.org	
  
•  Copy	
  jar	
  fi...
Simple	
  Scrip-ng	
  
•  Add	
  Thread	
  Group	
  (1	
  user)	
  
•  Add	
  FireFox	
  Driver	
  Config	
  (easiest	
  to...
Simple	
  Scrip-ng	
  
•  WDS.sampleResult.sampleStart()	
  
•  Do	
  some	
  stuff	
  	
  
•  WDS.sampleResult.sampleEnd()...
Mul-	
  Step	
  Scrip-ng	
  
•  Add	
  More	
  Webdriver	
  Samplers	
  
•  Each	
  Sampler	
  ConCnues	
  Same	
  Session...
CSV	
  Files	
  
•  Use	
  Standard	
  CSV	
  Data	
  Set	
  Config	
  Element	
  
•  Variables	
  are	
  referenced	
  as	...
Genera-ng	
  Load	
  with	
  BlazeMeter	
  
1.  Create	
  script	
  and	
  debug	
  locally	
  
2.  Upload	
  to	
  BlazeM...
Genera-ng	
  Load	
  with	
  BlazeMeter	
  
•  Free	
  Users	
  –	
  one	
  machine	
  with	
  up	
  to	
  5	
  browsers	
...
DEMO	
  
THANK	
  YOU	
  FOR	
  YOUR	
  TIME!	
  	
  
Q	
  &	
  A	
  
For more information:
BlazeMeter.com/blog	
   info@blazemeter...
Upcoming SlideShare
Loading in …5
×

Performance Testing using Real Browsers with JMeter & Webdriver

Learn how to easily run performance tests with real browsers using Selenium WebDriver.

Ophir Prusak, BlazeMeter’s Chief Evangelist, gives step-by-step instructions on doing this using BlazeMeter and/or JMeter.

Learn how to:

- Correlate actual browser-based user experience with the load tests

- Run multiple Selenium Webdriver tests in parallel at scale by using the power of the cloud

- Do it all without any prior JMeter knowledge or experience!

  • Login to see the comments

Performance Testing using Real Browsers with JMeter & Webdriver

  1. 1. Performance  Tes-ng  with  Real  Browsers   Harnessing  the  power  of  JMeter  &  Selenium  Webdriver   785 Castro Street, Mountain View, CA 94041 | 1.855.445.2285 | info@blazemeter.com BlazeMeter OPHIR  PRUSAK   Chief  Evangelist  -­‐  BlazeMeter  
  2. 2. AGENDA   •  JMeter  vs  Real  Browsers   •  Installing  the  JMeter  Webdriver  Plugin   •  CreaCng  Basic  Scripts   •  MulC  Step  Scripts   •  Adding  CSV  files   •  GeneraCng  Load  in  the  Cloud  with  BlazeMeter   •  Q&A  
  3. 3. About  BlazeMeter   API  |  Mobile  |  Web  |  CI  |  Load  &  Performance  TesCng  |  Cloud  &  Behind  the  Firewall   Open  Source   Compa-ble     (JMeter  &  Webdriver)   100%  Backend   Applica-on  Tes-ng   (Performance  &  API)   Self  Served   Pure  SAAS   Cloud   Tap  Into  the  Largest     Developers  Community  in  the   World  (Open  Source)  
  4. 4. JMeter  vs  Real  Browsers   Real  Browsers   •  AcCvity  defined  in  terms  of  user  acCons   –  Enter  URL  in  the  address  bar   –  Click  on  an  element   –  Enter  keystrokes   •  Browser  executes  addiConal  acCons   –  Parse  HTML   –  Executes  JavaScript   –  Understands  Form  Logic  
  5. 5. JMeter  vs  Real  Browsers   JMeter   •  AcCvity  defined  in  terms  of  HTTP  acCons   –  HTTP  GET,  HTTP  POST,  etc   –  Supports  Cookies  and  Caching   –  User  Variables,  Response  Data  ExtracCon  and  Flow  Logic   •  JMeter  does  not  execute  most  client  side  logic   –  Parse  HTML   –  Executes  JavaScript   –  Understands  Form  Logic  
  6. 6. Resource  Requirements   JMeter  vs  Real  Browsers   JMeter   Real  Browsers   300  to  2000  virtual  users  per  server   1  to  3  virtual  users  per  CPU  core   8  GB,  4  core  machine    =  1,000  users   8  GB,  4  core  machine  =  4-­‐12  users  
  7. 7. Installing  JMeter  Webdriver  Plugin   •  Download  Zip  from  jmeter-­‐plugins.org   •  Copy  jar  files  into  lib  and  lib/ext  directories   •  Delete  older  /  duplicate  HTTP  jars  
  8. 8. Simple  Scrip-ng   •  Add  Thread  Group  (1  user)   •  Add  FireFox  Driver  Config  (easiest  to  get  working)   –  FireFox  26.0  works.  Later  versions  not  guaranteed.   •  Add  Sampler  /  Webdriver  Sampler   •  Enter  Webdriver  Code   •  Add  Listeners  for  Debugging   •  Run  Test      
  9. 9. Simple  Scrip-ng   •  WDS.sampleResult.sampleStart()   •  Do  some  stuff     •  WDS.sampleResult.sampleEnd()   •  Tutorials   •  hcp://jmeter-­‐plugins.org/wiki/WebDriverTutorial/   •  hcp://jmeter-­‐plugins.org/wiki/WebDriverSampler/   •  hcp://blazemeter.com/blog/webdriver-­‐sampler-­‐your-­‐top-­‐10-­‐quesCons-­‐answered  
  10. 10. Mul-  Step  Scrip-ng   •  Add  More  Webdriver  Samplers   •  Each  Sampler  ConCnues  Same  Session   •  Each  Thread  IteraCon  is  a  New  Session  
  11. 11. CSV  Files   •  Use  Standard  CSV  Data  Set  Config  Element   •  Variables  are  referenced  as  ${varname}   –  For  example   –  WDS.browser.findElement(pkg.By.id('zipCode')).sendKeys(['${zip}'])
  12. 12. Genera-ng  Load  with  BlazeMeter   1.  Create  script  and  debug  locally   2.  Upload  to  BlazeMeter  and  set  load  parameters   1.  Currently  running  Webdriver  1.1.2   2.  Firefox  browsers  for  webdriver  tests   3.  Phantom.js  and  Chrome  support  coming  soon   3.  Run  test   4.  For  errors,  check  log  files  
  13. 13. Genera-ng  Load  with  BlazeMeter   •  Free  Users  –  one  machine  with  up  to  5  browsers   •  Paid  Accounts  –  up  to  20  browsers  per  server   •  Enterprise  Accounts  –  up  to  1,000  servers  /  per  test  
  14. 14. DEMO  
  15. 15. THANK  YOU  FOR  YOUR  TIME!     Q  &  A   For more information: BlazeMeter.com/blog   info@blazemeter.com   @BlazeMeter  

×