diff options
author | Robert Speicher <rspeicher@gmail.com> | 2017-06-05 21:51:54 +0300 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2017-06-20 02:59:01 +0300 |
commit | 018ed2c42fc946592e2b72d2e74710e509df0199 (patch) | |
tree | 81aa1cedbe184d2e9399c045583fb8b0761d8bb4 /spec/support | |
parent | 45fb1f9542fc258d8671c82843d681277ae4aa89 (diff) |
Change `login_with` uses to `gitlab_sign_in`
Change single `login_via` use to `gitlab_sign_in_via`
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/features/issuable_slash_commands_shared_examples.rb | 8 | ||||
-rw-r--r-- | spec/support/login_helpers.rb | 4 |
2 files changed, 6 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 db39e8dfd89..023bdfc833f 100644 --- a/spec/support/features/issuable_slash_commands_shared_examples.rb +++ b/spec/support/features/issuable_slash_commands_shared_examples.rb @@ -17,7 +17,7 @@ shared_examples 'issuable record that supports quick actions in its description project.team << [master, :master] project.team << [assignee, :developer] project.team << [guest, :guest] - login_with(master) + gitlab_sign_in(master) end after do @@ -106,7 +106,7 @@ shared_examples 'issuable record that supports quick actions in its description context "when current user cannot close #{issuable_type}" do before do logout - login_with(guest) + gitlab_sign_in(guest) visit public_send("namespace_project_#{issuable_type}_path", project.namespace, project, issuable) end @@ -141,7 +141,7 @@ shared_examples 'issuable record that supports quick actions in its description context "when current user cannot reopen #{issuable_type}" do before do logout - login_with(guest) + gitlab_sign_in(guest) visit public_send("namespace_project_#{issuable_type}_path", project.namespace, project, issuable) end @@ -171,7 +171,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 logout - login_with(guest) + gitlab_sign_in(guest) visit public_send("namespace_project_#{issuable_type}_path", project.namespace, project, issuable) end diff --git a/spec/support/login_helpers.rb b/spec/support/login_helpers.rb index cd6af454f48..879386b5437 100644 --- a/spec/support/login_helpers.rb +++ b/spec/support/login_helpers.rb @@ -14,7 +14,7 @@ module LoginHelpers # # Provide an existing User record # user = create(:user) # gitlab_sign_in(user) - def gitlab_sign_in(user_or_role) + def gitlab_sign_in(user_or_role, **kwargs) @user = if user_or_role.is_a?(User) user_or_role @@ -22,7 +22,7 @@ module LoginHelpers create(user_or_role) end - gitlab_sign_in_with(@user) + gitlab_sign_in_with(@user, **kwargs) end def gitlab_sign_in_via(provider, user, uid) |