Welcome to mirror list, hosted at ThFree Co, Russian Federation.

sorting_helper.rb « helpers « support « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 3801d25fb63669140396251c8940164a17134665 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# frozen_string_literal: true

# Helper allows you to sort items
#
# Params
#   value - value for sorting
#
# Usage:
#   include SortingHelper
#
#   sorting_by('Oldest updated')
#
module SortingHelper
  def sorting_by(value)
    find('.filter-dropdown-container button.dropdown-menu-toggle').click
    page.within('.content ul.dropdown-menu.dropdown-menu-right li') do
      click_link value
    end
  end
end