KEMBAR78
Robot Framework Introduction & Sauce Labs Integration | PDF
Presenters:
Bryan Lamb- robotframeworktutorial.com
Chris Broesamle- saucelabs.com
Tool Introduction
& Saucelabs.com Integration
Agenda
ž  About me
ž  Demo!
ž  What is a Test Automation “Framework”?
ž  Robot Framework Origin & History
ž  Features & Capabilities (Demo)
ž  Robot Framework vs. Selenium
ž  How to Install
ž  Simple Web Script (Demo)
ž  Layered/Page Objects Web Script (Demo)
ž  Saucelabs.com Example (Demo)
ž  Jenkins/Parallel Execution (Acceleration Demo)
ž  Where to Find Out More
ž  Q&A
About Me
ž  20 Years QA/Development/Leadership
ž  Apple, Macromedia, Yahoo, Experian
ž  Founder of RobotFrameworkTutorial.com
Robot Framework Demo
ž  Run the tests
—  API
—  File Sytem
—  Website
—  DB (SQL Server & MySql)
—  XML
ž  Examine the Amazing Results File
What is a Test Automation Framework
ž  Language
ž  Scripts
ž  Reusable page/entity objects
ž  Supporting libraries (web, API, DB, mobile)
ž  Abstraction layer for increased readability
ž  Test runner with selective run capabilities (tags)
ž  Suite/test setup & teardown (recovery)
ž  Reports
—  results summary/aggregation
—  timestamps
—  drill downs
—  search
—  embedded screenshots
ž  Scheduler/CI Integration
ž  Parallel Execution
ž  Conventions
Origin & History
ž  2005
—  Developed in Finland
—  Ideas shaped in Pekka Klärck's masters thesis
—  1.0 developed at Nokia Siemens Networks
ž  2008
—  Version 2.0 released as open source
software
ž  Current Version: 2.8.7
Pekka Klärck
Features & Capabilities
ž  Cross-Platform (Win, Mac, Linux)
ž  Keyword-Driven (w/ Data-driven capabilities)
—  Natural Language/Business Domain
—  Libraries (Demo of RF Website):
Built-In
External (pip install xxxxx)
OperatingSystem
Process
Dialogs String XML
Collections DateTime Screen Shot
Selenium2 Appium FTP SSH
Database Diff Swing Archive
Robot Framework “vs.” Selenium
Built-In Libraries
External Libraries (pip install xxxxx)
OperatingSystem
Process
Dialogs String XML
Collections DateTime Screen Shot
Robot Framework Script (.robot)
Selenium2 Appium FTP SSH
Database Diff Swing Archive
Hint: It “is” Selenium
Robot Framework vs. Selenium
Typical C# Selenium- Steeper learning curve for QA
Robot Framework vs. Selenium
Robot Framework Keywords- Not as intimidating for QA
Robot Framework vs. Cucumber (Gherkin)
Robot Framework can do Gherkin too!
How to Install
ž  Cross-platform (Win, Mac, Linux)
ž  Installation is small, light, and fast
ž  Requires some command line basics
ž  Steps
—  Install Python & PIP (add to your PATH)
○  Use PIP to install Robot Framework
○  Use PIP to install Selenium2 Library
○  Use PIP to install DB & API Libraries
—  Select & install desired browser versions
—  Install Selenium Webdrivers for each browser
—  Install the Pycharm IDE & Intellibot plugin
ž  Full details at robotframeworktutorial.com
Simple Web Script (Demo from Scratch)
Robot Framework
Selenium Webdriver
Selenium2 Library
Script (.robot)
Layered/Page Objects Example (Demos)
Test Cases (.robot)
User-Defined Keywords (.robot)
Page Object 1 Page Object 2
Selenium Webdrivers
Selenium2Library
Saucelabs.com Example
Robot Framework
Optional
-  Sauce Connect
-  Multiple Jenkins Slaves
Saucelabs.com Example (Demo)
ž  2 Steps*
1.  Add remote_url and desired_capabilities to
your Open Browser keyword (variables)
2.  Create a custom library which uses API call to
report test results back to Saucelabs
ž  Override the desired capabilities variable
from the command line to switch platforms
—  * Course available at robotframeworktutorial.com
Jenkins/Parallel Execution (Demo)
ž  *Jenkins can be used as a web GUI wrapper
around the Windows command line
—  “1 Click” script execution
—  Enables scheduling, etc.
ž  “Build Flow” plugin enables parallel execution
ž  Jenkins Robot Framework plugin keeps
results history, graphs, etc.
ž  * Course available at robotframeworktutorial.com
Where to Find Out More
ž  robotframework.org has docs & examples
ž  robotframeworktutorial.com training videos
ž  Groups/Forums
—  Linkedin
—  Google
—  Facebook
—  StackOverflow
Q&A
ž  How is development time vs. a Selenium fwk?
ž  CSS or XPath for locators?
ž  Will it work for AngularJS?
ž  Does it support Windows controls/apps?
ž  Can it be used for testing Flash?
ž  Can it be used for testing mobile apps?
ž  How does it compare to Page Object Model?
ž  Can it iterate over datasets/key:value pairs?
ž  How to run pabot on Jenkins & Sauce?

Robot Framework Introduction & Sauce Labs Integration

  • 1.
    Presenters: Bryan Lamb- robotframeworktutorial.com ChrisBroesamle- saucelabs.com Tool Introduction & Saucelabs.com Integration
  • 2.
    Agenda ž  About me ž Demo! ž  What is a Test Automation “Framework”? ž  Robot Framework Origin & History ž  Features & Capabilities (Demo) ž  Robot Framework vs. Selenium ž  How to Install ž  Simple Web Script (Demo) ž  Layered/Page Objects Web Script (Demo) ž  Saucelabs.com Example (Demo) ž  Jenkins/Parallel Execution (Acceleration Demo) ž  Where to Find Out More ž  Q&A
  • 3.
    About Me ž  20Years QA/Development/Leadership ž  Apple, Macromedia, Yahoo, Experian ž  Founder of RobotFrameworkTutorial.com
  • 4.
    Robot Framework Demo ž Run the tests —  API —  File Sytem —  Website —  DB (SQL Server & MySql) —  XML ž  Examine the Amazing Results File
  • 5.
    What is aTest Automation Framework ž  Language ž  Scripts ž  Reusable page/entity objects ž  Supporting libraries (web, API, DB, mobile) ž  Abstraction layer for increased readability ž  Test runner with selective run capabilities (tags) ž  Suite/test setup & teardown (recovery) ž  Reports —  results summary/aggregation —  timestamps —  drill downs —  search —  embedded screenshots ž  Scheduler/CI Integration ž  Parallel Execution ž  Conventions
  • 6.
    Origin & History ž 2005 —  Developed in Finland —  Ideas shaped in Pekka Klärck's masters thesis —  1.0 developed at Nokia Siemens Networks ž  2008 —  Version 2.0 released as open source software ž  Current Version: 2.8.7 Pekka Klärck
  • 7.
    Features & Capabilities ž Cross-Platform (Win, Mac, Linux) ž  Keyword-Driven (w/ Data-driven capabilities) —  Natural Language/Business Domain —  Libraries (Demo of RF Website): Built-In External (pip install xxxxx) OperatingSystem Process Dialogs String XML Collections DateTime Screen Shot Selenium2 Appium FTP SSH Database Diff Swing Archive
  • 8.
    Robot Framework “vs.”Selenium Built-In Libraries External Libraries (pip install xxxxx) OperatingSystem Process Dialogs String XML Collections DateTime Screen Shot Robot Framework Script (.robot) Selenium2 Appium FTP SSH Database Diff Swing Archive Hint: It “is” Selenium
  • 9.
    Robot Framework vs.Selenium Typical C# Selenium- Steeper learning curve for QA
  • 10.
    Robot Framework vs.Selenium Robot Framework Keywords- Not as intimidating for QA
  • 11.
    Robot Framework vs.Cucumber (Gherkin) Robot Framework can do Gherkin too!
  • 12.
    How to Install ž Cross-platform (Win, Mac, Linux) ž  Installation is small, light, and fast ž  Requires some command line basics ž  Steps —  Install Python & PIP (add to your PATH) ○  Use PIP to install Robot Framework ○  Use PIP to install Selenium2 Library ○  Use PIP to install DB & API Libraries —  Select & install desired browser versions —  Install Selenium Webdrivers for each browser —  Install the Pycharm IDE & Intellibot plugin ž  Full details at robotframeworktutorial.com
  • 13.
    Simple Web Script(Demo from Scratch) Robot Framework Selenium Webdriver Selenium2 Library Script (.robot)
  • 14.
    Layered/Page Objects Example(Demos) Test Cases (.robot) User-Defined Keywords (.robot) Page Object 1 Page Object 2 Selenium Webdrivers Selenium2Library
  • 15.
    Saucelabs.com Example Robot Framework Optional - Sauce Connect -  Multiple Jenkins Slaves
  • 16.
    Saucelabs.com Example (Demo) ž 2 Steps* 1.  Add remote_url and desired_capabilities to your Open Browser keyword (variables) 2.  Create a custom library which uses API call to report test results back to Saucelabs ž  Override the desired capabilities variable from the command line to switch platforms —  * Course available at robotframeworktutorial.com
  • 17.
    Jenkins/Parallel Execution (Demo) ž *Jenkins can be used as a web GUI wrapper around the Windows command line —  “1 Click” script execution —  Enables scheduling, etc. ž  “Build Flow” plugin enables parallel execution ž  Jenkins Robot Framework plugin keeps results history, graphs, etc. ž  * Course available at robotframeworktutorial.com
  • 18.
    Where to FindOut More ž  robotframework.org has docs & examples ž  robotframeworktutorial.com training videos ž  Groups/Forums —  Linkedin —  Google —  Facebook —  StackOverflow
  • 19.
    Q&A ž  How isdevelopment time vs. a Selenium fwk? ž  CSS or XPath for locators? ž  Will it work for AngularJS? ž  Does it support Windows controls/apps? ž  Can it be used for testing Flash? ž  Can it be used for testing mobile apps? ž  How does it compare to Page Object Model? ž  Can it iterate over datasets/key:value pairs? ž  How to run pabot on Jenkins & Sauce?