Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
9836017c
Commit
9836017c
authored
Sep 02, 2015
by
Valery Sizov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
satisfy rubocop
parent
81fe6f9d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
1 deletion
+26
-1
features/login_form.feature
features/login_form.feature
+1
-1
features/steps/login_form.rb
features/steps/login_form.rb
+25
-0
No files found.
features/
crowd_
login_form.feature
→
features/login_form.feature
View file @
9836017c
Feature
:
Crowd l
ogin form
Feature
:
L
ogin form
Scenario
:
I
see crowd form
Scenario
:
I
see crowd form
Given
Crowd integration enabled
Given
Crowd integration enabled
When
I visit sign in page
When
I visit sign in page
...
...
features/steps/
crowd_
login_form.rb
→
features/steps/login_form.rb
View file @
9836017c
class
Spinach::Features::
Crowd
LoginForm
<
Spinach
::
FeatureSteps
class
Spinach::Features::LoginForm
<
Spinach
::
FeatureSteps
include
SharedAuthentication
include
SharedAuthentication
include
SharedPaths
include
SharedPaths
include
SharedSnippet
include
SharedSnippet
...
@@ -6,16 +6,20 @@ class Spinach::Features::CrowdLoginForm < Spinach::FeatureSteps
...
@@ -6,16 +6,20 @@ class Spinach::Features::CrowdLoginForm < Spinach::FeatureSteps
include
SharedSearch
include
SharedSearch
step
'Crowd integration enabled'
do
step
'Crowd integration enabled'
do
Gitlab
::
OAuth
::
Provider
.
should_receive
(
:providers
).
and_return
([
:crowd
])
@providers_orig
=
Gitlab
::
OAuth
::
Provider
.
providers
@omniauth_conf_orig
=
Gitlab
.
config
.
omniauth
.
enabled
expect
(
Gitlab
::
OAuth
::
Provider
).
to
receive
(
:providers
).
and_return
([
:crowd
])
allow_any_instance_of
(
ApplicationHelper
).
to
receive
(
:user_omniauth_authorize_path
).
and_return
(
root_path
)
allow_any_instance_of
(
ApplicationHelper
).
to
receive
(
:user_omniauth_authorize_path
).
and_return
(
root_path
)
Gitlab
.
config
.
omniauth
.
should_
receive
(
:enabled
).
and_return
(
true
)
expect
(
Gitlab
.
config
.
omniauth
).
to
receive
(
:enabled
).
and_return
(
true
)
end
end
step
'I should see Crowd login form'
do
step
'I should see Crowd login form'
do
expect
(
page
).
to
have_selector
'#tab-crowd form'
expect
(
page
).
to
have_selector
'#tab-crowd form'
Gitlab
::
OAuth
::
Provider
.
stub
(
:providers
).
and_return
(
@providers_orig
)
Gitlab
.
config
.
omniauth
.
stub
(
:enabled
).
and_return
(
@omniauth_conf_orig
)
end
end
step
'I visit sign in page'
do
step
'I visit sign in page'
do
visit
new_user_session_path
visit
new_user_session_path
end
end
end
end
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment