Presentation is loading. Please wait.

Presentation is loading. Please wait.

Page Object Model (Rspec/Capybara)

Similar presentations


Presentation on theme: "Page Object Model (Rspec/Capybara)"— Presentation transcript:

1 Page Object Model (Rspec/Capybara)
Page Object Model pros & cons SitePrism Rspec Capybara Example & Useful links

2 Page Object Model pros & cons
Page Object Model (POM) is a design pattern to create Object Repository for web UI elements. A page object is an object-oriented class that serves as an interface to a page of your AUT Page Object Page Base Object Tests UI Page

3 SitePrism A Page Object Model DSL(Domain Specific Language) for Capybara Gives a simple, clean and semantic DSL for describing a site using the Page Object Model pattern Creating a Page Model Adding a URL Page Title

4 SitePrism Individual Elements (css, xpath) Elements
Testing for existence of elements Checking that all mapped elements are present on the page

5 Rspec Popular Ruby testing framework
Behavior-Driven Development tool – natural syntax Well formatted output

6 Rspec – example Functional requirements:
For wire transfer, IBAN for reimbursement and periodicity is required

7 Rspec – example Functional requirements:
For wire transfer, IBAN for reimbursement and periodicity is required

8 Capybara A library/gem built to be used on top of an underlying web-based driver, in our case Selenium Intuitive API which mimics the language an actual user would use. click_button('button_name') fill_in('First Name', :with => 'John') choose('A Radio Button') check('A Checkbox') attach_file('Image', '/path/to/image.jpg') Powerful synchronization

9 Example & Useful links Omnimut App SitePrism RSpec Capybara
SitePrism RSpec Capybara

10 Thank you!


Download ppt "Page Object Model (Rspec/Capybara)"

Similar presentations


Ads by Google