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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
e8f222e3
Commit
e8f222e3
authored
Jun 13, 2014
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix helper specs
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
a7345e36
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
spec/helpers/application_helper_spec.rb
spec/helpers/application_helper_spec.rb
+4
-5
No files found.
spec/helpers/application_helper_spec.rb
View file @
e8f222e3
...
...
@@ -67,10 +67,9 @@ describe ApplicationHelper do
end
it
"should call gravatar_icon when no avatar is present"
do
user
=
create
(
:user
)
user
=
create
(
:user
,
email:
'test@example.com'
)
user
.
save!
allow
(
self
).
to
receive
(
:gravatar_icon
).
and_return
(
'gravatar_method_called'
)
avatar_icon
(
user
.
email
).
to_s
.
should
==
"gravatar_method_called"
avatar_icon
(
user
.
email
).
to_s
.
should
==
"http://www.gravatar.com/avatar/55502f40dc8b7c769880b10874abc9d0?s=40&d=mm"
end
end
...
...
@@ -87,12 +86,12 @@ describe ApplicationHelper do
end
it
"should return default gravatar url"
do
allow
(
self
).
to
receive
(
:request
).
and_return
(
double
(
:ssl?
=>
false
)
)
Gitlab
.
config
.
gitlab
.
stub
(
https:
false
)
gravatar_icon
(
user_email
).
should
match
(
'http://www.gravatar.com/avatar/b58c6f14d292556214bd64909bcdb118'
)
end
it
"should use SSL when appropriate"
do
allow
(
self
).
to
receive
(
:request
).
and_return
(
double
(
:ssl?
=>
true
)
)
Gitlab
.
config
.
gitlab
.
stub
(
https:
true
)
gravatar_icon
(
user_email
).
should
match
(
'https://secure.gravatar.com'
)
end
...
...
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