summaryrefslogtreecommitdiff
path: root/features
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2016-02-26 11:27:27 +0000
committerRémy Coutable <remy@rymai.me>2016-02-26 11:27:27 +0000
commitbb3563b5cd063772fa16c934404e7912d9f3d726 (patch)
tree29494d63dabb5ff9d72cb32fc0229636b4bc7b46 /features
parent3f83d1dc3a6af8854747d695847c75ba41d25cb0 (diff)
parentb95ef77e233eab3b3d37a4a7dce545d9da36f8a0 (diff)
downloadgitlab-ce-bb3563b5cd063772fa16c934404e7912d9f3d726.tar.gz
Merge branch 'rs-crowd-form-view-spec' into 'master'
Move "I should see Crowd login form" feature to a view spec We were doing all kinds of code gymnastics to "enable" Crowd in the feature spec and this would sometimes cause a transient failure. Really what it's testing is if the Crowd login form shows when Crowd's enabled, so this is much better suited to a view spec. See merge request !2963
Diffstat (limited to 'features')
-rw-r--r--features/login_form.feature11
-rw-r--r--features/steps/login_form.rb25
2 files changed, 0 insertions, 36 deletions
diff --git a/features/login_form.feature b/features/login_form.feature
deleted file mode 100644
index 7965882f7fc..00000000000
--- a/features/login_form.feature
+++ /dev/null
@@ -1,11 +0,0 @@
-Feature: Login form
- Scenario: I see Crowd form
- Given Crowd integration enabled
- When I visit sign in page
- Then I should see Crowd login form
-
- Scenario: I see Crowd form when sign-in is disabled
- Given Crowd integration enabled
- And Sign-in is disabled
- When I visit sign in page
- Then I should see Crowd login form
diff --git a/features/steps/login_form.rb b/features/steps/login_form.rb
deleted file mode 100644
index 90ab10e6229..00000000000
--- a/features/steps/login_form.rb
+++ /dev/null
@@ -1,25 +0,0 @@
-class Spinach::Features::LoginForm < Spinach::FeatureSteps
- include SharedAuthentication
- include SharedPaths
- include SharedSnippet
- include SharedUser
- include SharedSearch
-
- step 'Sign-in is disabled' do
- allow_any_instance_of(ApplicationHelper).to receive(:signin_enabled?).and_return(false)
- end
-
- step 'Crowd integration enabled' do
- expect(Gitlab::OAuth::Provider).to receive(:providers).and_return([:crowd])
- expect(Gitlab.config.omniauth).to receive(:enabled).and_return(true)
- allow_any_instance_of(ApplicationHelper).to receive(:user_omniauth_authorize_path).and_return(root_path)
- end
-
- step 'I should see Crowd login form' do
- expect(page).to have_selector '#tab-crowd form'
- end
-
- step 'I visit sign in page' do
- visit new_user_session_path
- end
-end