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
2c4488d5
Commit
2c4488d5
authored
Apr 19, 2021
by
Huzaifa Iftikhar
Committed by
Kerri Miller
Apr 19, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix EmptyLineAfterFinalLetItBe Rubocop offenses for helpers
parent
3c50a67b
Changes
16
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
24 additions
and
14 deletions
+24
-14
.rubocop_manual_todo.yml
.rubocop_manual_todo.yml
+0
-14
changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-helpers.yml
...d/issue-325836-fix-empty-line-after-let-it-be-helpers.yml
+5
-0
spec/helpers/blob_helper_spec.rb
spec/helpers/blob_helper_spec.rb
+1
-0
spec/helpers/broadcast_messages_helper_spec.rb
spec/helpers/broadcast_messages_helper_spec.rb
+1
-0
spec/helpers/ci/runners_helper_spec.rb
spec/helpers/ci/runners_helper_spec.rb
+1
-0
spec/helpers/invite_members_helper_spec.rb
spec/helpers/invite_members_helper_spec.rb
+3
-0
spec/helpers/jira_connect_helper_spec.rb
spec/helpers/jira_connect_helper_spec.rb
+1
-0
spec/helpers/labels_helper_spec.rb
spec/helpers/labels_helper_spec.rb
+1
-0
spec/helpers/markup_helper_spec.rb
spec/helpers/markup_helper_spec.rb
+2
-0
spec/helpers/notes_helper_spec.rb
spec/helpers/notes_helper_spec.rb
+2
-0
spec/helpers/projects/alert_management_helper_spec.rb
spec/helpers/projects/alert_management_helper_spec.rb
+1
-0
spec/helpers/projects/issues/service_desk_helper_spec.rb
spec/helpers/projects/issues/service_desk_helper_spec.rb
+1
-0
spec/helpers/projects/project_members_helper_spec.rb
spec/helpers/projects/project_members_helper_spec.rb
+2
-0
spec/helpers/projects/terraform_helper_spec.rb
spec/helpers/projects/terraform_helper_spec.rb
+1
-0
spec/helpers/projects_helper_spec.rb
spec/helpers/projects_helper_spec.rb
+1
-0
spec/helpers/search_helper_spec.rb
spec/helpers/search_helper_spec.rb
+1
-0
No files found.
.rubocop_manual_todo.yml
View file @
2c4488d5
...
@@ -682,20 +682,6 @@ RSpec/EmptyLineAfterFinalLetItBe:
...
@@ -682,20 +682,6 @@ RSpec/EmptyLineAfterFinalLetItBe:
-
spec/graphql/resolvers/project_pipeline_resolver_spec.rb
-
spec/graphql/resolvers/project_pipeline_resolver_spec.rb
-
spec/graphql/resolvers/project_pipelines_resolver_spec.rb
-
spec/graphql/resolvers/project_pipelines_resolver_spec.rb
-
spec/graphql/resolvers/timelog_resolver_spec.rb
-
spec/graphql/resolvers/timelog_resolver_spec.rb
-
spec/helpers/blob_helper_spec.rb
-
spec/helpers/broadcast_messages_helper_spec.rb
-
spec/helpers/ci/runners_helper_spec.rb
-
spec/helpers/invite_members_helper_spec.rb
-
spec/helpers/jira_connect_helper_spec.rb
-
spec/helpers/labels_helper_spec.rb
-
spec/helpers/markup_helper_spec.rb
-
spec/helpers/notes_helper_spec.rb
-
spec/helpers/projects/alert_management_helper_spec.rb
-
spec/helpers/projects/issues/service_desk_helper_spec.rb
-
spec/helpers/projects/project_members_helper_spec.rb
-
spec/helpers/projects/terraform_helper_spec.rb
-
spec/helpers/projects_helper_spec.rb
-
spec/helpers/search_helper_spec.rb
-
spec/lib/bulk_imports/groups/loaders/group_loader_spec.rb
-
spec/lib/bulk_imports/groups/loaders/group_loader_spec.rb
-
spec/lib/extracts_path_spec.rb
-
spec/lib/extracts_path_spec.rb
-
spec/lib/extracts_ref_spec.rb
-
spec/lib/extracts_ref_spec.rb
...
...
changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-helpers.yml
0 → 100644
View file @
2c4488d5
---
title
:
Fix EmptyLineAfterFinalLetItBe Rubocop offenses for helpers
merge_request
:
58192
author
:
Huzaifa Iftikhar @huzaifaiftikhar
type
:
fixed
spec/helpers/blob_helper_spec.rb
View file @
2c4488d5
...
@@ -304,6 +304,7 @@ RSpec.describe BlobHelper do
...
@@ -304,6 +304,7 @@ RSpec.describe BlobHelper do
let_it_be
(
:namespace
)
{
create
(
:namespace
,
name:
'gitlab'
)
}
let_it_be
(
:namespace
)
{
create
(
:namespace
,
name:
'gitlab'
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
,
namespace:
namespace
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
,
namespace:
namespace
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let
(
:can_push_code
)
{
true
}
let
(
:can_push_code
)
{
true
}
let
(
:blob
)
{
project
.
repository
.
blob_at
(
'refs/heads/master'
,
'README.md'
)
}
let
(
:blob
)
{
project
.
repository
.
blob_at
(
'refs/heads/master'
,
'README.md'
)
}
...
...
spec/helpers/broadcast_messages_helper_spec.rb
View file @
2c4488d5
...
@@ -28,6 +28,7 @@ RSpec.describe BroadcastMessagesHelper do
...
@@ -28,6 +28,7 @@ RSpec.describe BroadcastMessagesHelper do
describe
'broadcast_message'
do
describe
'broadcast_message'
do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:current_broadcast_message
)
{
BroadcastMessage
.
new
(
message:
'Current Message'
)
}
let
(
:current_broadcast_message
)
{
BroadcastMessage
.
new
(
message:
'Current Message'
)
}
before
do
before
do
...
...
spec/helpers/ci/runners_helper_spec.rb
View file @
2c4488d5
...
@@ -84,6 +84,7 @@ RSpec.describe Ci::RunnersHelper do
...
@@ -84,6 +84,7 @@ RSpec.describe Ci::RunnersHelper do
describe
'#toggle_shared_runners_settings_data'
do
describe
'#toggle_shared_runners_settings_data'
do
let_it_be
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let
(
:project_with_runners
)
{
create
(
:project
,
namespace:
group
,
shared_runners_enabled:
true
)
}
let
(
:project_with_runners
)
{
create
(
:project
,
namespace:
group
,
shared_runners_enabled:
true
)
}
let
(
:project_without_runners
)
{
create
(
:project
,
namespace:
group
,
shared_runners_enabled:
false
)
}
let
(
:project_without_runners
)
{
create
(
:project
,
namespace:
group
,
shared_runners_enabled:
false
)
}
...
...
spec/helpers/invite_members_helper_spec.rb
View file @
2c4488d5
...
@@ -5,6 +5,7 @@ require "spec_helper"
...
@@ -5,6 +5,7 @@ require "spec_helper"
RSpec
.
describe
InviteMembersHelper
do
RSpec
.
describe
InviteMembersHelper
do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:developer
)
{
create
(
:user
,
developer_projects:
[
project
])
}
let_it_be
(
:developer
)
{
create
(
:user
,
developer_projects:
[
project
])
}
let
(
:owner
)
{
project
.
owner
}
let
(
:owner
)
{
project
.
owner
}
before
do
before
do
...
@@ -253,6 +254,7 @@ RSpec.describe InviteMembersHelper do
...
@@ -253,6 +254,7 @@ RSpec.describe InviteMembersHelper do
context
'with a project'
do
context
'with a project'
do
let_it_be
(
:form_model
)
{
project
}
let_it_be
(
:form_model
)
{
project
}
let
(
:link_href
)
{
"href=
\"
#{
project_project_members_path
(
form_model
)
}
\"
"
}
let
(
:link_href
)
{
"href=
\"
#{
project_project_members_path
(
form_model
)
}
\"
"
}
it_behaves_like
'dropdown invite members link'
it_behaves_like
'dropdown invite members link'
...
@@ -260,6 +262,7 @@ RSpec.describe InviteMembersHelper do
...
@@ -260,6 +262,7 @@ RSpec.describe InviteMembersHelper do
context
'with a group'
do
context
'with a group'
do
let_it_be
(
:form_model
)
{
create
(
:group
)
}
let_it_be
(
:form_model
)
{
create
(
:group
)
}
let
(
:link_href
)
{
"href=
\"
#{
group_group_members_path
(
form_model
)
}
\"
"
}
let
(
:link_href
)
{
"href=
\"
#{
group_group_members_path
(
form_model
)
}
\"
"
}
it_behaves_like
'dropdown invite members link'
it_behaves_like
'dropdown invite members link'
...
...
spec/helpers/jira_connect_helper_spec.rb
View file @
2c4488d5
...
@@ -5,6 +5,7 @@ require 'spec_helper'
...
@@ -5,6 +5,7 @@ require 'spec_helper'
RSpec
.
describe
JiraConnectHelper
do
RSpec
.
describe
JiraConnectHelper
do
describe
'#jira_connect_app_data'
do
describe
'#jira_connect_app_data'
do
let_it_be
(
:subscription
)
{
create
(
:jira_connect_subscription
)
}
let_it_be
(
:subscription
)
{
create
(
:jira_connect_subscription
)
}
let
(
:user
)
{
create
(
:user
)
}
let
(
:user
)
{
create
(
:user
)
}
subject
{
helper
.
jira_connect_app_data
([
subscription
])
}
subject
{
helper
.
jira_connect_app_data
([
subscription
])
}
...
...
spec/helpers/labels_helper_spec.rb
View file @
2c4488d5
...
@@ -36,6 +36,7 @@ RSpec.describe LabelsHelper do
...
@@ -36,6 +36,7 @@ RSpec.describe LabelsHelper do
context
'with a group label'
do
context
'with a group label'
do
let_it_be
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let
(
:label
)
{
create
(
:group_label
,
group:
group
,
title:
'bug'
)
}
let
(
:label
)
{
create
(
:group_label
,
group:
group
,
title:
'bug'
)
}
context
'when asking for an issue link'
do
context
'when asking for an issue link'
do
...
...
spec/helpers/markup_helper_spec.rb
View file @
2c4488d5
...
@@ -13,6 +13,7 @@ RSpec.describe MarkupHelper do
...
@@ -13,6 +13,7 @@ RSpec.describe MarkupHelper do
let_it_be
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
let_it_be
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
let_it_be
(
:merge_request
)
{
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)
}
let_it_be
(
:merge_request
)
{
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)
}
let_it_be
(
:snippet
)
{
create
(
:project_snippet
,
project:
project
)
}
let_it_be
(
:snippet
)
{
create
(
:project_snippet
,
project:
project
)
}
let
(
:commit
)
{
project
.
commit
}
let
(
:commit
)
{
project
.
commit
}
before
do
before
do
...
@@ -453,6 +454,7 @@ FooBar
...
@@ -453,6 +454,7 @@ FooBar
let_it_be
(
:project_base
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project_base
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:context
)
{
{
project:
project_base
}
}
let_it_be
(
:context
)
{
{
project:
project_base
}
}
let
(
:file_name
)
{
'foo.bar'
}
let
(
:file_name
)
{
'foo.bar'
}
let
(
:text
)
{
'Noël'
}
let
(
:text
)
{
'Noël'
}
...
...
spec/helpers/notes_helper_spec.rb
View file @
2c4488d5
...
@@ -15,6 +15,7 @@ RSpec.describe NotesHelper do
...
@@ -15,6 +15,7 @@ RSpec.describe NotesHelper do
let_it_be
(
:owner_note
)
{
create
(
:note
,
author:
owner
,
project:
project
)
}
let_it_be
(
:owner_note
)
{
create
(
:note
,
author:
owner
,
project:
project
)
}
let_it_be
(
:maintainer_note
)
{
create
(
:note
,
author:
maintainer
,
project:
project
)
}
let_it_be
(
:maintainer_note
)
{
create
(
:note
,
author:
maintainer
,
project:
project
)
}
let_it_be
(
:reporter_note
)
{
create
(
:note
,
author:
reporter
,
project:
project
)
}
let_it_be
(
:reporter_note
)
{
create
(
:note
,
author:
reporter
,
project:
project
)
}
let!
(
:notes
)
{
[
owner_note
,
maintainer_note
,
reporter_note
]
}
let!
(
:notes
)
{
[
owner_note
,
maintainer_note
,
reporter_note
]
}
before_all
do
before_all
do
...
@@ -73,6 +74,7 @@ RSpec.describe NotesHelper do
...
@@ -73,6 +74,7 @@ RSpec.describe NotesHelper do
describe
'#discussion_path'
do
describe
'#discussion_path'
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:anchor
)
{
discussion
.
line_code
}
let
(
:anchor
)
{
discussion
.
line_code
}
context
'for a merge request discusion'
do
context
'for a merge request discusion'
do
...
...
spec/helpers/projects/alert_management_helper_spec.rb
View file @
2c4488d5
...
@@ -7,6 +7,7 @@ RSpec.describe Projects::AlertManagementHelper do
...
@@ -7,6 +7,7 @@ RSpec.describe Projects::AlertManagementHelper do
let_it_be
(
:project
,
reload:
true
)
{
create
(
:project
)
}
let_it_be
(
:project
,
reload:
true
)
{
create
(
:project
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let
(
:project_path
)
{
project
.
full_path
}
let
(
:project_path
)
{
project
.
full_path
}
let
(
:project_id
)
{
project
.
id
}
let
(
:project_id
)
{
project
.
id
}
...
...
spec/helpers/projects/issues/service_desk_helper_spec.rb
View file @
2c4488d5
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
Projects
::
Issues
::
ServiceDeskHelper
do
RSpec
.
describe
Projects
::
Issues
::
ServiceDeskHelper
do
let_it_be
(
:project
)
{
create
(
:project
,
:public
,
service_desk_enabled:
true
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:public
,
service_desk_enabled:
true
)
}
let
(
:user
)
{
build_stubbed
(
:user
)
}
let
(
:user
)
{
build_stubbed
(
:user
)
}
let
(
:current_user
)
{
user
}
let
(
:current_user
)
{
user
}
...
...
spec/helpers/projects/project_members_helper_spec.rb
View file @
2c4488d5
...
@@ -128,6 +128,7 @@ RSpec.describe Projects::ProjectMembersHelper do
...
@@ -128,6 +128,7 @@ RSpec.describe Projects::ProjectMembersHelper do
describe
"when current user is not the owner of the project's parent group"
do
describe
"when current user is not the owner of the project's parent group"
do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:project2
)
{
create
(
:project
,
namespace:
group
)
}
let
(
:project2
)
{
create
(
:project
,
namespace:
group
)
}
before
do
before
do
...
@@ -174,6 +175,7 @@ RSpec.describe Projects::ProjectMembersHelper do
...
@@ -174,6 +175,7 @@ RSpec.describe Projects::ProjectMembersHelper do
describe
'project group links'
do
describe
'project group links'
do
let_it_be
(
:project_group_links
)
{
create_list
(
:project_group_link
,
1
,
project:
project
)
}
let_it_be
(
:project_group_links
)
{
create_list
(
:project_group_link
,
1
,
project:
project
)
}
let
(
:allow_admin_project
)
{
true
}
let
(
:allow_admin_project
)
{
true
}
describe
'#project_group_links_data_json'
do
describe
'#project_group_links_data_json'
do
...
...
spec/helpers/projects/terraform_helper_spec.rb
View file @
2c4488d5
...
@@ -5,6 +5,7 @@ require 'spec_helper'
...
@@ -5,6 +5,7 @@ require 'spec_helper'
RSpec
.
describe
Projects
::
TerraformHelper
do
RSpec
.
describe
Projects
::
TerraformHelper
do
describe
'#js_terraform_list_data'
do
describe
'#js_terraform_list_data'
do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let
(
:current_user
)
{
project
.
creator
}
let
(
:current_user
)
{
project
.
creator
}
subject
{
helper
.
js_terraform_list_data
(
current_user
,
project
)
}
subject
{
helper
.
js_terraform_list_data
(
current_user
,
project
)
}
...
...
spec/helpers/projects_helper_spec.rb
View file @
2c4488d5
...
@@ -85,6 +85,7 @@ RSpec.describe ProjectsHelper do
...
@@ -85,6 +85,7 @@ RSpec.describe ProjectsHelper do
describe
"can_change_visibility_level?"
do
describe
"can_change_visibility_level?"
do
let_it_be
(
:user
)
{
create
(
:project_member
,
:reporter
,
user:
create
(
:user
),
project:
project
).
user
}
let_it_be
(
:user
)
{
create
(
:project_member
,
:reporter
,
user:
create
(
:user
),
project:
project
).
user
}
let
(
:forked_project
)
{
fork_project
(
project
,
user
)
}
let
(
:forked_project
)
{
fork_project
(
project
,
user
)
}
it
"returns false if there are no appropriate permissions"
do
it
"returns false if there are no appropriate permissions"
do
...
...
spec/helpers/search_helper_spec.rb
View file @
2c4488d5
...
@@ -489,6 +489,7 @@ RSpec.describe SearchHelper do
...
@@ -489,6 +489,7 @@ RSpec.describe SearchHelper do
describe
'#repository_ref'
do
describe
'#repository_ref'
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:params
)
{
{
repository_ref:
'the-repository-ref-param'
}
}
let
(
:params
)
{
{
repository_ref:
'the-repository-ref-param'
}
}
subject
{
repository_ref
(
project
)
}
subject
{
repository_ref
(
project
)
}
...
...
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