Method: PageObject::PageFactory#visit_page

Defined in:
lib/page-object/page_factory.rb

#visit_page(page_class, params = {:using_params => {}}, &block) ⇒ PageObject Also known as: visit

Create and navigate to a page object. The navigation will only work if the ‘page_url’ method was call on the page object.

PageObject module or a string containing the name of the class available in the @params instance variable.

Parameters:

  • a (PageObject, String)

    class that has included the

  • Hash

    values that is pass through to page class a

  • an

    optional block to be called

Returns:



52
53
54
# File 'lib/page-object/page_factory.rb', line 52

def visit_page(page_class, params={:using_params => {}}, &block)
  on_page page_class, params, true, &block
end