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
144d7080
Commit
144d7080
authored
Mar 18, 2021
by
Sam Beckham
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed failing rspec tests for helpers
parent
c0698511
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
spec/helpers/snippets_helper_spec.rb
spec/helpers/snippets_helper_spec.rb
+3
-3
spec/helpers/wiki_helper_spec.rb
spec/helpers/wiki_helper_spec.rb
+1
-1
No files found.
spec/helpers/snippets_helper_spec.rb
View file @
144d7080
...
...
@@ -32,7 +32,7 @@ RSpec.describe SnippetsHelper do
end
def
download_link
(
url
)
"<a class=
\"
btn
\"
target=
\"
_blank
\"
rel=
\"
noopener noreferrer
\"
title=
\"
Open raw
\"
href=
\"
#{
url
}
\"
>
#{
external_snippet_icon
(
'doc-code'
)
}
</a>"
"<a class=
\"
gl-button btn btn-default
\"
target=
\"
_blank
\"
rel=
\"
noopener noreferrer
\"
title=
\"
Open raw
\"
href=
\"
#{
url
}
\"
>
#{
external_snippet_icon
(
'doc-code'
)
}
</a>"
end
end
...
...
@@ -59,7 +59,7 @@ RSpec.describe SnippetsHelper do
end
def
download_link
(
url
)
"<a class=
\"
btn
\"
target=
\"
_blank
\"
title=
\"
Download
\"
rel=
\"
noopener noreferrer
\"
href=
\"
#{
url
}
?inline=false
\"
>
#{
external_snippet_icon
(
'download'
)
}
</a>"
"<a class=
\"
gl-button btn btn-default
\"
target=
\"
_blank
\"
title=
\"
Download
\"
rel=
\"
noopener noreferrer
\"
href=
\"
#{
url
}
?inline=false
\"
>
#{
external_snippet_icon
(
'download'
)
}
</a>"
end
end
...
...
@@ -83,7 +83,7 @@ RSpec.describe SnippetsHelper do
end
def
download_link
(
url
)
"<a target=
\"
_blank
\"
rel=
\"
noopener noreferrer
\"
class=
\"
btn
btn-sm has-tooltip
\"
title=
\"
Download
\"
data-container=
\"
body
\"
href=
\"
#{
url
}
?inline=false
\"
>
#{
sprite_icon
(
'download'
)
}
</a>"
"<a target=
\"
_blank
\"
rel=
\"
noopener noreferrer
\"
class=
\"
gl-button btn btn-default
btn-sm has-tooltip
\"
title=
\"
Download
\"
data-container=
\"
body
\"
href=
\"
#{
url
}
?inline=false
\"
>
#{
sprite_icon
(
'download'
)
}
</a>"
end
end
...
...
spec/helpers/wiki_helper_spec.rb
View file @
144d7080
...
...
@@ -76,7 +76,7 @@ RSpec.describe WikiHelper do
describe
'#wiki_sort_controls'
do
let
(
:wiki
)
{
create
(
:project_wiki
)
}
let
(
:wiki_link
)
{
helper
.
wiki_sort_controls
(
wiki
,
sort
,
direction
)
}
let
(
:classes
)
{
"btn btn-default has-tooltip reverse-sort-btn qa-reverse-sort rspec-reverse-sort"
}
let
(
:classes
)
{
"
gl-button
btn btn-default has-tooltip reverse-sort-btn qa-reverse-sort rspec-reverse-sort"
}
def
expected_link
(
sort
,
direction
,
icon_class
)
path
=
"/
#{
wiki
.
project
.
full_path
}
/-/wikis/pages?direction=
#{
direction
}
&sort=
#{
sort
}
"
...
...
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