diff options
author | Valery Sizov <valery@gitlab.com> | 2016-11-07 21:36:58 +0300 |
---|---|---|
committer | Valery Sizov <valery@gitlab.com> | 2016-11-08 13:03:23 +0300 |
commit | ebc44befdc773b39a171d38dc13c38cd6630828a (patch) | |
tree | b52776fb22c732bafaf89e280a072118be2374b9 /spec/features/global_search_spec.rb | |
parent | 6be0c160d346c67967e541a76b6fbf6fc1ba2456 (diff) |
Fix broken commits search
Diffstat (limited to 'spec/features/global_search_spec.rb')
-rw-r--r-- | spec/features/global_search_spec.rb | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/spec/features/global_search_spec.rb b/spec/features/global_search_spec.rb new file mode 100644 index 00000000000..f6409e00f22 --- /dev/null +++ b/spec/features/global_search_spec.rb @@ -0,0 +1,28 @@ +require 'spec_helper' + +feature 'Global search', feature: true do + let(:user) { create(:user) } + let(:project) { create(:project, namespace: user.namespace) } + + before do + project.team << [user, :master] + login_with(user) + end + + describe 'I search through the issues and I see pagination' do + before do + allow_any_instance_of(Gitlab::SearchResults).to receive(:per_page).and_return(1) + create_list(:issue, 2, project: project, title: 'initial') + end + + it "has a pagination" do + visit dashboard_projects_path + + fill_in "search", with: "initial" + click_button "Go" + + select_filter("Issues") + expect(page).to have_selector('.gl-pagination .page', count: 2) + end + end +end |