diff options
author | Robert Speicher <rspeicher@gmail.com> | 2017-06-21 18:44:10 -0500 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2017-06-29 12:18:23 -0400 |
commit | e939bf7be10b6ec516ffbe75ad4b4dc1151670a7 (patch) | |
tree | 7d59f3f1fad2b83c1cd051562d6375fd4bbf0a7a /spec/support | |
parent | 5a983ac431affc800d5e9db9e83c14710ec29c36 (diff) | |
download | gitlab-ce-e939bf7be10b6ec516ffbe75ad4b4dc1151670a7.tar.gz |
Change gitlab_sign_in to sign_in where possible
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/features/issuable_slash_commands_shared_examples.rb | 9 | ||||
-rw-r--r-- | spec/support/features/rss_shared_examples.rb | 4 |
2 files changed, 7 insertions, 6 deletions
diff --git a/spec/support/features/issuable_slash_commands_shared_examples.rb b/spec/support/features/issuable_slash_commands_shared_examples.rb index 98b014df6cd..98b7e3d3255 100644 --- a/spec/support/features/issuable_slash_commands_shared_examples.rb +++ b/spec/support/features/issuable_slash_commands_shared_examples.rb @@ -17,7 +17,8 @@ shared_examples 'issuable record that supports quick actions in its description project.team << [master, :master] project.team << [assignee, :developer] project.team << [guest, :guest] - gitlab_sign_in(master) + + sign_in(master) end after do @@ -111,7 +112,7 @@ shared_examples 'issuable record that supports quick actions in its description context "when current user cannot close #{issuable_type}" do before do gitlab_sign_out - gitlab_sign_in(guest) + sign_in(guest) visit public_send("namespace_project_#{issuable_type}_path", project.namespace, project, issuable) end @@ -146,7 +147,7 @@ shared_examples 'issuable record that supports quick actions in its description context "when current user cannot reopen #{issuable_type}" do before do gitlab_sign_out - gitlab_sign_in(guest) + sign_in(guest) visit public_send("namespace_project_#{issuable_type}_path", project.namespace, project, issuable) end @@ -176,7 +177,7 @@ shared_examples 'issuable record that supports quick actions in its description context "when current user cannot change title of #{issuable_type}" do before do gitlab_sign_out - gitlab_sign_in(guest) + sign_in(guest) visit public_send("namespace_project_#{issuable_type}_path", project.namespace, project, issuable) end diff --git a/spec/support/features/rss_shared_examples.rb b/spec/support/features/rss_shared_examples.rb index 1cbb4134995..50fbbc7f55b 100644 --- a/spec/support/features/rss_shared_examples.rb +++ b/spec/support/features/rss_shared_examples.rb @@ -1,12 +1,12 @@ shared_examples "an autodiscoverable RSS feed with current_user's RSS token" do it "has an RSS autodiscovery link tag with current_user's RSS token" do - expect(page).to have_css("link[type*='atom+xml'][href*='rss_token=#{Thread.current[:current_user].rss_token}']", visible: false) + expect(page).to have_css("link[type*='atom+xml'][href*='rss_token=#{user.rss_token}']", visible: false) end end shared_examples "it has an RSS button with current_user's RSS token" do it "shows the RSS button with current_user's RSS token" do - expect(page).to have_css("a:has(.fa-rss)[href*='rss_token=#{Thread.current[:current_user].rss_token}']") + expect(page).to have_css("a:has(.fa-rss)[href*='rss_token=#{user.rss_token}']") end end |