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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
09f2bec6
Commit
09f2bec6
authored
Jun 24, 2015
by
Robert Speicher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Prefix random Markdown tips with "Tip:"
parent
82a67170
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
app/helpers/gitlab_markdown_helper.rb
app/helpers/gitlab_markdown_helper.rb
+1
-1
spec/helpers/gitlab_markdown_helper_spec.rb
spec/helpers/gitlab_markdown_helper_spec.rb
+1
-1
No files found.
app/helpers/gitlab_markdown_helper.rb
View file @
09f2bec6
...
...
@@ -118,7 +118,7 @@ module GitlabMarkdownHelper
# Returns a random markdown tip for use as a textarea placeholder
def
random_markdown_tip
MARKDOWN_TIPS
.
sample
"Tip:
#{
MARKDOWN_TIPS
.
sample
}
"
end
private
...
...
spec/helpers/gitlab_markdown_helper_spec.rb
View file @
09f2bec6
...
...
@@ -137,7 +137,7 @@ describe GitlabMarkdownHelper do
describe
'random_markdown_tip'
do
it
'returns a random Markdown tip'
do
stub_const
(
"
#{
described_class
}
::MARKDOWN_TIPS"
,
[
'Random tip'
])
expect
(
random_markdown_tip
).
to
eq
'Random tip'
expect
(
random_markdown_tip
).
to
eq
'
Tip:
Random tip'
end
end
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