Testing with Jenkins, Selenium and Continuous Deployment
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Testing with Jenkins, Selenium and Continuous Deployment

on

  • 13,870 views

My talk about testing at KharkivPy#4

My talk about testing at KharkivPy#4

Statistics

Views

Total Views
13,870
Views on SlideShare
11,346
Embed Views
2,524

Actions

Likes
14
Downloads
126
Comments
0

42 Embeds 2,524

http://blog.klymyshyn.com 1626
http://djangoandother.blogspot.com 573
http://djangoandother.blogspot.co.uk 39
http://6805337420829225605_24c56fc0c0e39b50a392b5bd342f0a56180f3fa6.blogspot.com 34
http://djangoandother.blogspot.de 30
http://djangoandother.blogspot.fr 28
http://djangoandother.blogspot.ca 19
http://djangoandother.blogspot.ro 18
http://djangoandother.blogspot.it 15
http://djangoandother.blogspot.nl 12
http://djangoandother.blogspot.in 11
http://djangoandother.blogspot.com.au 11
http://djangoandother.blogspot.kr 10
http://djangoandother.blogspot.com.es 8
http://djangoandother.blogspot.com.br 7
http://djangoandother.blogspot.fi 7
http://djangoandother.blogspot.gr 7
http://djangoandother.blogspot.sg 6
http://djangoandother.blogspot.ch 6
http://djangoandother.blogspot.no 6
http://djangoandother.blogspot.se 5
http://djangoandother.blogspot.com.ar 4
http://www.linkedin.com 4
http://djangoandother.blogspot.cz 4
http://djangoandother.blogspot.co.nz 4
http://djangoandother.blogspot.co.at 3
http://djangoandother.blogspot.pt 3
http://djangoandother.blogspot.jp 3
http://djangoandother.blogspot.dk 3
https://twitter.com 2
http://djangoandother.blogspot.sk 2
http://djangoandother.blogspot.be 2
http://djangoandother.blogspot.ie 2
http://djangoandother.blogspot.co.il 2
http://www.verious.com 1
http://abtasty.com 1
http://djangoandother.blogspot.mx 1
http://translate.googleusercontent.com 1
http://djangoandother.blogspot.hk 1
http://djangoandother.blogspot.hu 1
http://djangoandother.blogspot.tw 1
https://www.linkedin.com 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Apple Keynote

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n

Testing with Jenkins, Selenium and Continuous Deployment Presentation Transcript

  • 1. Testing with Jenkins, Selenium and Continuous Deployment Max Klymyshyn oDesk PS Twitter: @maxmaxmaxmax Github: joymax
  • 2. The problemWe need to run our tests periodicallyTests execution take a lot of time, it’s not an option to run onintegrator’s machine all the timeWe want to run our Selenium tests on separated branchesWe don’t have persistent Selenium Grid nodesBlah blah, the CI problem...
  • 3. The solutionJenkins as Continuous Integration toolSelenium Grid + Tests execution service with Amazon AWSinstances on-demandDeployment tool which can deploy any version of the codewithin isolated environment
  • 4. TOCJenkins configurationSelenium Grid and Amazon AWS architectureDeployment tool with Fabric, Gunicorn, Nginx (+ Celery,Redis and Solr)Shortcuts for developersA bit about libraries development
  • 5. StackFlaskMongoSolrRedisCelery
  • 6. JenkinsCoverageTests results trend (junit reports)JSLintPylint
  • 7. Tests executionunit, integration, consistency tests with NoseLettuce for forms and overall site UXJavaScript tests with Rhino and Flask-JasmineSelenium UI tests
  • 8. Selenium Tests Execute tests Start selenium node(s) with requested browser(s) Execute selenium tests Shutdown node
  • 9. Selenium Tests and Jenkins Headless tests (pass) Deploy current commit Execute selenium tests Destroy deployed commit
  • 10. on-demand selenium nodesTests runner IE9 / Win IE8 / Win IE7 / WinService FF / Win Chrome / Win FF / LinuxSelenium Grid 2 Chrome / Linux
  • 11. Selenium tests during devDeveloper execute tests with specific browserIt’s not necessary to have browserIt’s possible to debug tests with IPDBIt’s possible to see what’s going on on remove node usingSelenium Node admin or making screenshots
  • 12. Tests runner configuration [runner]api_key=XXXXXXXXXnose_args=-vnose_single_test_args=-vcselenium_host=http://s.sample.com/wd/hubrpc_host=http://rpc.s.sample.com
  • 13. Browsers configuration [internetexplorer-9]name=internetexplorerversion=9platform=WINDOWS[internetexplorer-7]name=internetexplorerversion=7platform=WINDOWS
  • 14. Tests execution # Execute selenium tests in all browsersuitestrunner -c browsers.cfg -a# Execute synchronously in IE9 (+IPDB)uitestrunner -c browsers.cfg -s -binternetexplorer-9# Execute one test$ uitestrunner -c browsers.cfg -b internetexplorer-9 -t
  • 15. Deployment tool FTWGet commit or branch Create virtualenvAdd Solr core install requirementsCreate mongo DB gunicorn by templateGenerate local_settings celery by templatestart services nginx by template
  • 16. The flow for developersThe problem: QA engineer should check quality of each issue/branch Developer should provide “live” url to its branchSolution: Deploy specific branch Provide URL to it to QA engineer
  • 17. Shortcuts for developersExecute shortcuts in working branch:doit deploydoit destroydoit restartdoit cleanup_build
  • 18. SummaryEasy-to-demonstrate new changesEasy to QAAll team members informed about status
  • 19. Questions?