Skip to content

Make it possible to define reusable steps

Grzegorz Bizon requested to merge feature/page-scope-steps into master

This MR makes it possible to use steps, defined with page scope.

With this approach it will be possible to define some certain actions that can be performed on particular page, where page is a separate class, and step is a separate method in class.

Each time we do some check on GitLab, we start with Page::Main and sign_in_* (depending on which method we choose to sign in). Next we should choose the next page depending on what we did on the previous one, example:

Page::Main.on do
  sign_in_using_credentials
end

Side::Menu.on do
  go_to_groups
end

Page::Groups.on do
  add_new_group('Test namespace', :private)
end

expect(page).to have_content('@test-namespace')

Merge request reports