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
18048a60
Commit
18048a60
authored
Sep 30, 2019
by
Thong Kuah
Committed by
James Lopez
Sep 30, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add frozen_string_literal to helper specs
https://gitlab.com/gitlab-org/gitlab/issues/27703
parent
33c2a94c
Changes
57
Hide whitespace changes
Inline
Side-by-side
Showing
57 changed files
with
116 additions
and
4 deletions
+116
-4
app/helpers/submodule_helper.rb
app/helpers/submodule_helper.rb
+1
-1
spec/helpers/application_helper_spec.rb
spec/helpers/application_helper_spec.rb
+2
-0
spec/helpers/auto_devops_helper_spec.rb
spec/helpers/auto_devops_helper_spec.rb
+2
-0
spec/helpers/avatars_helper_spec.rb
spec/helpers/avatars_helper_spec.rb
+2
-0
spec/helpers/award_emoji_helper_spec.rb
spec/helpers/award_emoji_helper_spec.rb
+2
-0
spec/helpers/blame_helper_spec.rb
spec/helpers/blame_helper_spec.rb
+2
-0
spec/helpers/blob_helper_spec.rb
spec/helpers/blob_helper_spec.rb
+2
-0
spec/helpers/boards_helper_spec.rb
spec/helpers/boards_helper_spec.rb
+2
-0
spec/helpers/broadcast_messages_helper_spec.rb
spec/helpers/broadcast_messages_helper_spec.rb
+2
-0
spec/helpers/button_helper_spec.rb
spec/helpers/button_helper_spec.rb
+2
-0
spec/helpers/calendar_helper_spec.rb
spec/helpers/calendar_helper_spec.rb
+2
-0
spec/helpers/ci_status_helper_spec.rb
spec/helpers/ci_status_helper_spec.rb
+2
-0
spec/helpers/commits_helper_spec.rb
spec/helpers/commits_helper_spec.rb
+2
-0
spec/helpers/components_helper_spec.rb
spec/helpers/components_helper_spec.rb
+2
-0
spec/helpers/dashboard_helper_spec.rb
spec/helpers/dashboard_helper_spec.rb
+2
-0
spec/helpers/defer_script_tag_helper_spec.rb
spec/helpers/defer_script_tag_helper_spec.rb
+2
-0
spec/helpers/emails_helper_spec.rb
spec/helpers/emails_helper_spec.rb
+2
-0
spec/helpers/events_helper_spec.rb
spec/helpers/events_helper_spec.rb
+2
-0
spec/helpers/explore_helper_spec.rb
spec/helpers/explore_helper_spec.rb
+2
-0
spec/helpers/form_helper_spec.rb
spec/helpers/form_helper_spec.rb
+2
-0
spec/helpers/git_helper_spec.rb
spec/helpers/git_helper_spec.rb
+2
-0
spec/helpers/gitlab_routing_helper_spec.rb
spec/helpers/gitlab_routing_helper_spec.rb
+2
-0
spec/helpers/graph_helper_spec.rb
spec/helpers/graph_helper_spec.rb
+2
-0
spec/helpers/hooks_helper_spec.rb
spec/helpers/hooks_helper_spec.rb
+2
-0
spec/helpers/icons_helper_spec.rb
spec/helpers/icons_helper_spec.rb
+2
-0
spec/helpers/import_helper_spec.rb
spec/helpers/import_helper_spec.rb
+2
-0
spec/helpers/instance_configuration_helper_spec.rb
spec/helpers/instance_configuration_helper_spec.rb
+2
-0
spec/helpers/issues_helper_spec.rb
spec/helpers/issues_helper_spec.rb
+2
-0
spec/helpers/labels_helper_spec.rb
spec/helpers/labels_helper_spec.rb
+2
-0
spec/helpers/markup_helper_spec.rb
spec/helpers/markup_helper_spec.rb
+5
-3
spec/helpers/members_helper_spec.rb
spec/helpers/members_helper_spec.rb
+2
-0
spec/helpers/milestones_helper_spec.rb
spec/helpers/milestones_helper_spec.rb
+2
-0
spec/helpers/milestones_routing_helper_spec.rb
spec/helpers/milestones_routing_helper_spec.rb
+2
-0
spec/helpers/namespaces_helper_spec.rb
spec/helpers/namespaces_helper_spec.rb
+2
-0
spec/helpers/nav_helper_spec.rb
spec/helpers/nav_helper_spec.rb
+2
-0
spec/helpers/notes_helper_spec.rb
spec/helpers/notes_helper_spec.rb
+2
-0
spec/helpers/notifications_helper_spec.rb
spec/helpers/notifications_helper_spec.rb
+2
-0
spec/helpers/page_layout_helper_spec.rb
spec/helpers/page_layout_helper_spec.rb
+2
-0
spec/helpers/pagination_helper_spec.rb
spec/helpers/pagination_helper_spec.rb
+2
-0
spec/helpers/preferences_helper_spec.rb
spec/helpers/preferences_helper_spec.rb
+2
-0
spec/helpers/profiles_helper_spec.rb
spec/helpers/profiles_helper_spec.rb
+2
-0
spec/helpers/rss_helper_spec.rb
spec/helpers/rss_helper_spec.rb
+2
-0
spec/helpers/runners_helper_spec.rb
spec/helpers/runners_helper_spec.rb
+2
-0
spec/helpers/search_helper_spec.rb
spec/helpers/search_helper_spec.rb
+2
-0
spec/helpers/sidekiq_helper_spec.rb
spec/helpers/sidekiq_helper_spec.rb
+2
-0
spec/helpers/snippets_helper_spec.rb
spec/helpers/snippets_helper_spec.rb
+2
-0
spec/helpers/storage_helper_spec.rb
spec/helpers/storage_helper_spec.rb
+2
-0
spec/helpers/submodule_helper_spec.rb
spec/helpers/submodule_helper_spec.rb
+2
-0
spec/helpers/tab_helper_spec.rb
spec/helpers/tab_helper_spec.rb
+2
-0
spec/helpers/time_helper_spec.rb
spec/helpers/time_helper_spec.rb
+2
-0
spec/helpers/todos_helper_spec.rb
spec/helpers/todos_helper_spec.rb
+2
-0
spec/helpers/tree_helper_spec.rb
spec/helpers/tree_helper_spec.rb
+2
-0
spec/helpers/user_callouts_helper_spec.rb
spec/helpers/user_callouts_helper_spec.rb
+2
-0
spec/helpers/users_helper_spec.rb
spec/helpers/users_helper_spec.rb
+2
-0
spec/helpers/version_check_helper_spec.rb
spec/helpers/version_check_helper_spec.rb
+2
-0
spec/helpers/visibility_level_helper_spec.rb
spec/helpers/visibility_level_helper_spec.rb
+2
-0
spec/helpers/wiki_helper_spec.rb
spec/helpers/wiki_helper_spec.rb
+2
-0
No files found.
app/helpers/submodule_helper.rb
View file @
18048a60
...
@@ -81,7 +81,7 @@ module SubmoduleHelper
...
@@ -81,7 +81,7 @@ module SubmoduleHelper
end
end
def
relative_self_links
(
relative_path
,
commit
,
project
)
def
relative_self_links
(
relative_path
,
commit
,
project
)
relative_path
.
rstrip!
relative_path
=
relative_path
.
rstrip
absolute_project_path
=
"/"
+
project
.
full_path
absolute_project_path
=
"/"
+
project
.
full_path
# Resolve `relative_path` to target path
# Resolve `relative_path` to target path
...
...
spec/helpers/application_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
ApplicationHelper
do
describe
ApplicationHelper
do
...
...
spec/helpers/auto_devops_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
AutoDevopsHelper
do
describe
AutoDevopsHelper
do
...
...
spec/helpers/avatars_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
AvatarsHelper
do
describe
AvatarsHelper
do
...
...
spec/helpers/award_emoji_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
AwardEmojiHelper
do
describe
AwardEmojiHelper
do
...
...
spec/helpers/blame_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
BlameHelper
do
describe
BlameHelper
do
...
...
spec/helpers/blob_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
BlobHelper
do
describe
BlobHelper
do
...
...
spec/helpers/boards_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
BoardsHelper
do
describe
BoardsHelper
do
...
...
spec/helpers/broadcast_messages_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
BroadcastMessagesHelper
do
describe
BroadcastMessagesHelper
do
...
...
spec/helpers/button_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
ButtonHelper
do
describe
ButtonHelper
do
...
...
spec/helpers/calendar_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
CalendarHelper
do
describe
CalendarHelper
do
...
...
spec/helpers/ci_status_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
CiStatusHelper
do
describe
CiStatusHelper
do
...
...
spec/helpers/commits_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
CommitsHelper
do
describe
CommitsHelper
do
...
...
spec/helpers/components_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
ComponentsHelper
do
describe
ComponentsHelper
do
...
...
spec/helpers/dashboard_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
DashboardHelper
do
describe
DashboardHelper
do
...
...
spec/helpers/defer_script_tag_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
DeferScriptTagHelper
do
describe
DeferScriptTagHelper
do
...
...
spec/helpers/emails_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
EmailsHelper
do
describe
EmailsHelper
do
...
...
spec/helpers/events_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
EventsHelper
do
describe
EventsHelper
do
...
...
spec/helpers/explore_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
ExploreHelper
do
describe
ExploreHelper
do
...
...
spec/helpers/form_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
FormHelper
do
describe
FormHelper
do
...
...
spec/helpers/git_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
GitHelper
do
describe
GitHelper
do
...
...
spec/helpers/gitlab_routing_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
GitlabRoutingHelper
do
describe
GitlabRoutingHelper
do
...
...
spec/helpers/graph_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
GraphHelper
do
describe
GraphHelper
do
...
...
spec/helpers/hooks_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
HooksHelper
do
describe
HooksHelper
do
...
...
spec/helpers/icons_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
IconsHelper
do
describe
IconsHelper
do
...
...
spec/helpers/import_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
ImportHelper
do
describe
ImportHelper
do
...
...
spec/helpers/instance_configuration_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
InstanceConfigurationHelper
do
describe
InstanceConfigurationHelper
do
...
...
spec/helpers/issues_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
"spec_helper"
require
"spec_helper"
describe
IssuesHelper
do
describe
IssuesHelper
do
...
...
spec/helpers/labels_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
LabelsHelper
do
describe
LabelsHelper
do
...
...
spec/helpers/markup_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
MarkupHelper
do
describe
MarkupHelper
do
...
@@ -408,12 +410,12 @@ describe MarkupHelper do
...
@@ -408,12 +410,12 @@ describe MarkupHelper do
it
'preserves a link href when link text is truncated'
do
it
'preserves a link href when link text is truncated'
do
text
=
'The quick brown fox jumped over the lazy dog'
# 44 chars
text
=
'The quick brown fox jumped over the lazy dog'
# 44 chars
input
=
"
#{
text
}#{
text
}#{
text
}
"
# 133 chars
link_url
=
'http://example.com/foo/bar/baz'
# 30 chars
link_url
=
'http://example.com/foo/bar/baz'
# 30 chars
input
<<
link_url
input
=
"
#{
text
}#{
text
}#{
text
}
#{
link_url
}
"
# 163 chars
object
=
create_object
(
input
)
expected_link_text
=
'http://example...</a>'
expected_link_text
=
'http://example...</a>'
object
=
create_object
(
input
)
expect
(
first_line_in_markdown
(
object
,
attribute
,
150
,
project:
project
)).
to
match
(
link_url
)
expect
(
first_line_in_markdown
(
object
,
attribute
,
150
,
project:
project
)).
to
match
(
link_url
)
expect
(
first_line_in_markdown
(
object
,
attribute
,
150
,
project:
project
)).
to
match
(
expected_link_text
)
expect
(
first_line_in_markdown
(
object
,
attribute
,
150
,
project:
project
)).
to
match
(
expected_link_text
)
end
end
...
...
spec/helpers/members_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
MembersHelper
do
describe
MembersHelper
do
...
...
spec/helpers/milestones_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
MilestonesHelper
do
describe
MilestonesHelper
do
...
...
spec/helpers/milestones_routing_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
MilestonesRoutingHelper
do
describe
MilestonesRoutingHelper
do
...
...
spec/helpers/namespaces_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
NamespacesHelper
do
describe
NamespacesHelper
do
...
...
spec/helpers/nav_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
NavHelper
,
:do_not_mock_admin_mode
do
describe
NavHelper
,
:do_not_mock_admin_mode
do
...
...
spec/helpers/notes_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
"spec_helper"
require
"spec_helper"
describe
NotesHelper
do
describe
NotesHelper
do
...
...
spec/helpers/notifications_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
NotificationsHelper
do
describe
NotificationsHelper
do
...
...
spec/helpers/page_layout_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
PageLayoutHelper
do
describe
PageLayoutHelper
do
...
...
spec/helpers/pagination_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
PaginationHelper
do
describe
PaginationHelper
do
...
...
spec/helpers/preferences_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
PreferencesHelper
do
describe
PreferencesHelper
do
...
...
spec/helpers/profiles_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
ProfilesHelper
do
describe
ProfilesHelper
do
...
...
spec/helpers/rss_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
RssHelper
do
describe
RssHelper
do
...
...
spec/helpers/runners_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
RunnersHelper
do
describe
RunnersHelper
do
...
...
spec/helpers/search_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
SearchHelper
do
describe
SearchHelper
do
...
...
spec/helpers/sidekiq_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
SidekiqHelper
do
describe
SidekiqHelper
do
...
...
spec/helpers/snippets_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
SnippetsHelper
do
describe
SnippetsHelper
do
...
...
spec/helpers/storage_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
"spec_helper"
require
"spec_helper"
describe
StorageHelper
do
describe
StorageHelper
do
...
...
spec/helpers/submodule_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
SubmoduleHelper
do
describe
SubmoduleHelper
do
...
...
spec/helpers/tab_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
TabHelper
do
describe
TabHelper
do
...
...
spec/helpers/time_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
TimeHelper
do
describe
TimeHelper
do
...
...
spec/helpers/todos_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
"spec_helper"
require
"spec_helper"
describe
TodosHelper
do
describe
TodosHelper
do
...
...
spec/helpers/tree_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
TreeHelper
do
describe
TreeHelper
do
...
...
spec/helpers/user_callouts_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
"spec_helper"
require
"spec_helper"
describe
UserCalloutsHelper
do
describe
UserCalloutsHelper
do
...
...
spec/helpers/users_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
UsersHelper
do
describe
UsersHelper
do
...
...
spec/helpers/version_check_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
VersionCheckHelper
do
describe
VersionCheckHelper
do
...
...
spec/helpers/visibility_level_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
VisibilityLevelHelper
do
describe
VisibilityLevelHelper
do
...
...
spec/helpers/wiki_helper_spec.rb
View file @
18048a60
# frozen_string_literal: true
require
'spec_helper'
require
'spec_helper'
describe
WikiHelper
do
describe
WikiHelper
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