SlideShare ist ein Scribd-Unternehmen logo
1 von 15
Robot Framework 2.5 Robot Framework is a generic test automation framework for acceptance testing and acceptance test-driven development (ATDD). by Usov Borys
Features: Enables easy-to-use tabular syntax for creating test cases in a uniform way. Allows using keyword-driven, data-driven and behavior-driven (BDD) approaches. Provides easy-to-read reports and logs in HTML format. Is platform and application independent. Provides a simple library API for creating customized test libraries. Implemented with Python. Provides support for Selenium for web testing.
Test application: login.py Command > pythonsut/login.pyloginnobody P4ssw0rd Access Denied > pythonsut/login.pycreate fredinvalid Creatinguserfailed: Passwordmustbe a combinationoflowercase anduppercase letters and numbers > pythonsut/login.pycreate fred P4ssw0rd SUCCESS > pythonsut/login.pyloginfred P4ssw0rd Logged In Status
High-level test cases
Simple tabular syntax for test cases Keyword
User-defined keywords (tabular view) Function from user-defined library
Robot Framework Libraries ,[object Object]
Adding Libraries***Settings*** Library  /testlib/LoginLibrary.py Library  OperatingSystem Library  Screenshot #Test Setup  Create File  #Test Teardown  Take Screenshot
User-defined Libraries classLoginLibrary: def__init__(self): #Initialising class with path to our application self._status = ''   defcreate_user(self, username, password): self._run_command('create', username, password)   defattempt_to_login_with_credentials(self, username, password): self._run_command('login', username, password)   defchange_password(self, username, old_pwd, new_pwd): self._run_command('change-password', username, old_pwd, new_pwd)   defstatus_should_be(self, expected_status):         if expected_status != self._status:             raise AssertionError("Error")   def_run_command(self, command, *args): #Function runs command and sets result status to     #self._status variable
Plain text presentation of user-defined keywordsand variables ***Keywords*** #High-level test cases. Given a user has a valid account 	Create valid user	${USERNAME}	${PASSWORD} When he changes hispassword 	Change password	${USERNAME}	${PASSWORD}	${NEW PASSWORD} Then he can log in with the new password 	Login	${USERNAME}	${NEW PASSWORD} And he cannot use the old password anymore  	Attempt to login with credentials	${USERNAME}	${PASSWORD} 	Status should be	Access Denied ***Variables*** ${USERNAME}  busov ${PASSWORD}  P4s5wo0rd ${NEW PASSWORD}  e0D3n4J ${PWD INVALID LENGTH}  Password must be 7-12 characters long
Plain text test cases presentation ***Test Cases*** User can create an account and log in 	Create Valid User	fred	P4ssw0rd 	Attempt to Login with Credentials	fred	P4ssw0rd 	Status Should Be	Logged In User cannot log in with bad password 	Create Valid User	betty	P4ssw0rd 	Attempt to Login with Credentials	betty	wrong 	Status Should Be	Access Denied
Report in html format
Log file in html format
RIDE Robot Framework IDE
For more information Project Pages The main information hub http://code.google.com/p/robotframework User Guide Detailed information about all features of the framework http://code.google.com/p/robotframework/wiki/UserGuide

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

Scripting robot
Scripting robotScripting robot
Scripting robot
 
Introduction to Robot Framework
Introduction to Robot FrameworkIntroduction to Robot Framework
Introduction to Robot Framework
 
Introduction to robot framework
Introduction to robot frameworkIntroduction to robot framework
Introduction to robot framework
 
Robot framework
Robot frameworkRobot framework
Robot framework
 
Introduction to Robot Framework – Exove
Introduction to Robot Framework – ExoveIntroduction to Robot Framework – Exove
Introduction to Robot Framework – Exove
 
Functional Tests Automation with Robot Framework
Functional Tests Automation with Robot FrameworkFunctional Tests Automation with Robot Framework
Functional Tests Automation with Robot Framework
 
Introduction to jest
Introduction to jestIntroduction to jest
Introduction to jest
 
Test Automation Framework with BDD and Cucumber
Test Automation Framework with BDD and CucumberTest Automation Framework with BDD and Cucumber
Test Automation Framework with BDD and Cucumber
 
Robot Framework Introduction & Sauce Labs Integration
Robot Framework Introduction & Sauce Labs IntegrationRobot Framework Introduction & Sauce Labs Integration
Robot Framework Introduction & Sauce Labs Integration
 
Network Protocol Testing Using Robot Framework
Network Protocol Testing Using Robot FrameworkNetwork Protocol Testing Using Robot Framework
Network Protocol Testing Using Robot Framework
 
API Test Automation Using Karate (Anil Kumar Moka)
API Test Automation Using Karate (Anil Kumar Moka)API Test Automation Using Karate (Anil Kumar Moka)
API Test Automation Using Karate (Anil Kumar Moka)
 
Robot framework Gowthami Goli
Robot framework Gowthami GoliRobot framework Gowthami Goli
Robot framework Gowthami Goli
 
Testing of React JS app
Testing of React JS appTesting of React JS app
Testing of React JS app
 
Continuous Quality with Postman
Continuous Quality with PostmanContinuous Quality with Postman
Continuous Quality with Postman
 
Playwright: A New Test Automation Framework for the Modern Web
Playwright: A New Test Automation Framework for the Modern WebPlaywright: A New Test Automation Framework for the Modern Web
Playwright: A New Test Automation Framework for the Modern Web
 
Acceptance Test Driven Development and Robot Framework
Acceptance Test Driven Development and Robot FrameworkAcceptance Test Driven Development and Robot Framework
Acceptance Test Driven Development and Robot Framework
 
Postman & API Testing by Amber Race
Postman & API Testing by Amber RacePostman & API Testing by Amber Race
Postman & API Testing by Amber Race
 
Why Should we use Microsoft's Playwright
Why Should we use Microsoft's PlaywrightWhy Should we use Microsoft's Playwright
Why Should we use Microsoft's Playwright
 
TestNG Framework
TestNG Framework TestNG Framework
TestNG Framework
 
Cucumber BDD
Cucumber BDDCucumber BDD
Cucumber BDD
 

Andere mochten auch

Andere mochten auch (16)

Robot Framework Introduction
Robot Framework IntroductionRobot Framework Introduction
Robot Framework Introduction
 
JavaCro'14 - Test Automation using RobotFramework Libraries – Stojan Peshov
JavaCro'14 - Test Automation using RobotFramework Libraries – Stojan PeshovJavaCro'14 - Test Automation using RobotFramework Libraries – Stojan Peshov
JavaCro'14 - Test Automation using RobotFramework Libraries – Stojan Peshov
 
Acceptance testing plone sites and add ons with robot framework and selenium
Acceptance testing plone sites and add ons with robot framework and seleniumAcceptance testing plone sites and add ons with robot framework and selenium
Acceptance testing plone sites and add ons with robot framework and selenium
 
Introduction to Robot Framework (external)
Introduction to Robot Framework (external)Introduction to Robot Framework (external)
Introduction to Robot Framework (external)
 
Introduction to Robot Framework
Introduction to Robot FrameworkIntroduction to Robot Framework
Introduction to Robot Framework
 
Robot framework - Lord of the Rings
Robot framework - Lord of the RingsRobot framework - Lord of the Rings
Robot framework - Lord of the Rings
 
Robotframework Presentation - Pinoy Python Meetup 2011January12
Robotframework Presentation - Pinoy Python Meetup 2011January12Robotframework Presentation - Pinoy Python Meetup 2011January12
Robotframework Presentation - Pinoy Python Meetup 2011January12
 
Sphinx + robot framework = documentation as result of functional testing
Sphinx + robot framework = documentation as result of functional testingSphinx + robot framework = documentation as result of functional testing
Sphinx + robot framework = documentation as result of functional testing
 
Make product not war
Make product not warMake product not war
Make product not war
 
Understanding Your Group Life Insurance Benefit
Understanding Your Group Life Insurance BenefitUnderstanding Your Group Life Insurance Benefit
Understanding Your Group Life Insurance Benefit
 
Asciidoctor in 15min
Asciidoctor in 15minAsciidoctor in 15min
Asciidoctor in 15min
 
Appium solution artizone
Appium solution   artizoneAppium solution   artizone
Appium solution artizone
 
A Buffer's Guide to Selenium 2
A Buffer's Guide to Selenium 2A Buffer's Guide to Selenium 2
A Buffer's Guide to Selenium 2
 
Innovations Techniques Au Service Du Test De Recette Automatisé
Innovations Techniques Au Service Du Test De Recette AutomatiséInnovations Techniques Au Service Du Test De Recette Automatisé
Innovations Techniques Au Service Du Test De Recette Automatisé
 
Future of Mobile Automation, Appium Steals it
Future of Mobile Automation, Appium Steals itFuture of Mobile Automation, Appium Steals it
Future of Mobile Automation, Appium Steals it
 
Appium - test automation for mobile apps
Appium - test automation for mobile appsAppium - test automation for mobile apps
Appium - test automation for mobile apps
 

Ähnlich wie Robot framework

Intro To JavaScript Unit Testing - Ran Mizrahi
Intro To JavaScript Unit Testing - Ran MizrahiIntro To JavaScript Unit Testing - Ran Mizrahi
Intro To JavaScript Unit Testing - Ran Mizrahi
Ran Mizrahi
 
Powershell Tech Ed2009
Powershell Tech Ed2009Powershell Tech Ed2009
Powershell Tech Ed2009
rsnarayanan
 
SummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdf
SummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdfSummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdf
SummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdf
ARORACOCKERY2111
 
Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012
Michelangelo van Dam
 

Ähnlich wie Robot framework (20)

JavaEE Security
JavaEE SecurityJavaEE Security
JavaEE Security
 
Flex Maniacs 2007
Flex Maniacs 2007Flex Maniacs 2007
Flex Maniacs 2007
 
Simplify your professional web development with symfony
Simplify your professional web development with symfonySimplify your professional web development with symfony
Simplify your professional web development with symfony
 
Code Quality Practice and Tools
Code Quality Practice and ToolsCode Quality Practice and Tools
Code Quality Practice and Tools
 
Apex Testing and Best Practices
Apex Testing and Best PracticesApex Testing and Best Practices
Apex Testing and Best Practices
 
FluentSelenium Presentation Code Camp09
FluentSelenium Presentation Code Camp09FluentSelenium Presentation Code Camp09
FluentSelenium Presentation Code Camp09
 
Code your Own: Authentication Provider for Blackboard Learn
Code your Own: Authentication Provider for Blackboard LearnCode your Own: Authentication Provider for Blackboard Learn
Code your Own: Authentication Provider for Blackboard Learn
 
Workshop quality assurance for php projects tek12
Workshop quality assurance for php projects tek12Workshop quality assurance for php projects tek12
Workshop quality assurance for php projects tek12
 
Intro To JavaScript Unit Testing - Ran Mizrahi
Intro To JavaScript Unit Testing - Ran MizrahiIntro To JavaScript Unit Testing - Ran Mizrahi
Intro To JavaScript Unit Testing - Ran Mizrahi
 
Powershell Tech Ed2009
Powershell Tech Ed2009Powershell Tech Ed2009
Powershell Tech Ed2009
 
Data Validation models
Data Validation modelsData Validation models
Data Validation models
 
SummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdf
SummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdfSummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdf
SummaryHW6 Account ManagementIn HW4, you kept track of multiple.pdf
 
Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012
 
Test Automation Frameworks Final
Test Automation Frameworks   FinalTest Automation Frameworks   Final
Test Automation Frameworks Final
 
Bh Win 03 Rileybollefer
Bh Win 03 RileybolleferBh Win 03 Rileybollefer
Bh Win 03 Rileybollefer
 
JavaOne 2009 - TS-5276 - RESTful Protocol Buffers
JavaOne 2009 - TS-5276 - RESTful  Protocol BuffersJavaOne 2009 - TS-5276 - RESTful  Protocol Buffers
JavaOne 2009 - TS-5276 - RESTful Protocol Buffers
 
Os Leonard
Os LeonardOs Leonard
Os Leonard
 
Frisby Api automation
Frisby Api automationFrisby Api automation
Frisby Api automation
 
Brief introduction into SQL injection attack scenarios
Brief introduction into SQL injection attack scenariosBrief introduction into SQL injection attack scenarios
Brief introduction into SQL injection attack scenarios
 
Xml api-5.0-rev b
Xml api-5.0-rev bXml api-5.0-rev b
Xml api-5.0-rev b
 

Robot framework

  • 1. Robot Framework 2.5 Robot Framework is a generic test automation framework for acceptance testing and acceptance test-driven development (ATDD). by Usov Borys
  • 2. Features: Enables easy-to-use tabular syntax for creating test cases in a uniform way. Allows using keyword-driven, data-driven and behavior-driven (BDD) approaches. Provides easy-to-read reports and logs in HTML format. Is platform and application independent. Provides a simple library API for creating customized test libraries. Implemented with Python. Provides support for Selenium for web testing.
  • 3. Test application: login.py Command > pythonsut/login.pyloginnobody P4ssw0rd Access Denied > pythonsut/login.pycreate fredinvalid Creatinguserfailed: Passwordmustbe a combinationoflowercase anduppercase letters and numbers > pythonsut/login.pycreate fred P4ssw0rd SUCCESS > pythonsut/login.pyloginfred P4ssw0rd Logged In Status
  • 5. Simple tabular syntax for test cases Keyword
  • 6. User-defined keywords (tabular view) Function from user-defined library
  • 7.
  • 8. Adding Libraries***Settings*** Library /testlib/LoginLibrary.py Library OperatingSystem Library Screenshot #Test Setup Create File #Test Teardown Take Screenshot
  • 9. User-defined Libraries classLoginLibrary: def__init__(self): #Initialising class with path to our application self._status = ''   defcreate_user(self, username, password): self._run_command('create', username, password)   defattempt_to_login_with_credentials(self, username, password): self._run_command('login', username, password)   defchange_password(self, username, old_pwd, new_pwd): self._run_command('change-password', username, old_pwd, new_pwd)   defstatus_should_be(self, expected_status): if expected_status != self._status: raise AssertionError("Error")   def_run_command(self, command, *args): #Function runs command and sets result status to #self._status variable
  • 10. Plain text presentation of user-defined keywordsand variables ***Keywords*** #High-level test cases. Given a user has a valid account Create valid user ${USERNAME} ${PASSWORD} When he changes hispassword Change password ${USERNAME} ${PASSWORD} ${NEW PASSWORD} Then he can log in with the new password Login ${USERNAME} ${NEW PASSWORD} And he cannot use the old password anymore Attempt to login with credentials ${USERNAME} ${PASSWORD} Status should be Access Denied ***Variables*** ${USERNAME} busov ${PASSWORD} P4s5wo0rd ${NEW PASSWORD} e0D3n4J ${PWD INVALID LENGTH} Password must be 7-12 characters long
  • 11. Plain text test cases presentation ***Test Cases*** User can create an account and log in Create Valid User fred P4ssw0rd Attempt to Login with Credentials fred P4ssw0rd Status Should Be Logged In User cannot log in with bad password Create Valid User betty P4ssw0rd Attempt to Login with Credentials betty wrong Status Should Be Access Denied
  • 12. Report in html format
  • 13. Log file in html format
  • 15. For more information Project Pages The main information hub http://code.google.com/p/robotframework User Guide Detailed information about all features of the framework http://code.google.com/p/robotframework/wiki/UserGuide

Hinweis der Redaktion

  1. Action could be keyword or a function from library
  2. Return to slide number 4