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
Kazuhiko Shiozaki
gitlab-ce
Commits
f993130b
Commit
f993130b
authored
Feb 13, 2016
by
Robert Speicher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix specs expecting `emoji/` in image path
parent
fe13f58f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
spec/helpers/gitlab_markdown_helper_spec.rb
spec/helpers/gitlab_markdown_helper_spec.rb
+1
-1
spec/lib/banzai/filter/emoji_filter_spec.rb
spec/lib/banzai/filter/emoji_filter_spec.rb
+2
-2
No files found.
spec/helpers/gitlab_markdown_helper_spec.rb
View file @
f993130b
...
@@ -113,7 +113,7 @@ describe GitlabMarkdownHelper do
...
@@ -113,7 +113,7 @@ describe GitlabMarkdownHelper do
it
'should replace commit message with emoji to link'
do
it
'should replace commit message with emoji to link'
do
actual
=
link_to_gfm
(
':book:Book'
,
'/foo'
)
actual
=
link_to_gfm
(
':book:Book'
,
'/foo'
)
expect
(
actual
).
expect
(
actual
).
to
eq
%Q(<img class="emoji" title=":book:" alt=":book:" src="http://localhost/assets/
emoji/
1F4D6.png" height="20" width="20" align="absmiddle"><a href="/foo">Book</a>)
to
eq
%Q(<img class="emoji" title=":book:" alt=":book:" src="http://localhost/assets/1F4D6.png" height="20" width="20" align="absmiddle"><a href="/foo">Book</a>)
end
end
end
end
...
...
spec/lib/banzai/filter/emoji_filter_spec.rb
View file @
f993130b
...
@@ -14,7 +14,7 @@ describe Banzai::Filter::EmojiFilter, lib: true do
...
@@ -14,7 +14,7 @@ describe Banzai::Filter::EmojiFilter, lib: true do
it
'replaces supported emoji'
do
it
'replaces supported emoji'
do
doc
=
filter
(
'<p>:heart:</p>'
)
doc
=
filter
(
'<p>:heart:</p>'
)
expect
(
doc
.
css
(
'img'
).
first
.
attr
(
'src'
)).
to
eq
'https://foo.com/assets/
emoji/
2764.png'
expect
(
doc
.
css
(
'img'
).
first
.
attr
(
'src'
)).
to
eq
'https://foo.com/assets/2764.png'
end
end
it
'ignores unsupported emoji'
do
it
'ignores unsupported emoji'
do
...
@@ -25,7 +25,7 @@ describe Banzai::Filter::EmojiFilter, lib: true do
...
@@ -25,7 +25,7 @@ describe Banzai::Filter::EmojiFilter, lib: true do
it
'correctly encodes the URL'
do
it
'correctly encodes the URL'
do
doc
=
filter
(
'<p>:+1:</p>'
)
doc
=
filter
(
'<p>:+1:</p>'
)
expect
(
doc
.
css
(
'img'
).
first
.
attr
(
'src'
)).
to
eq
'https://foo.com/assets/
emoji/
1F44D.png'
expect
(
doc
.
css
(
'img'
).
first
.
attr
(
'src'
)).
to
eq
'https://foo.com/assets/1F44D.png'
end
end
it
'matches at the start of a string'
do
it
'matches at the start of a string'
do
...
...
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