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
10fd73c4
Commit
10fd73c4
authored
Apr 14, 2021
by
Huzaifa Iftikhar
Committed by
Matthias Käppler
Apr 14, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix EmptyLineAfterFinalLetItBe offenses in spec/serializers
parent
cedcd442
Changes
24
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
30 additions
and
22 deletions
+30
-22
.rubocop_manual_todo.yml
.rubocop_manual_todo.yml
+0
-22
changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-serializers.yml
...sue-325836-fix-empty-line-after-let-it-be-serializers.yml
+5
-0
spec/serializers/admin/user_entity_spec.rb
spec/serializers/admin/user_entity_spec.rb
+1
-0
spec/serializers/ci/lint/result_serializer_spec.rb
spec/serializers/ci/lint/result_serializer_spec.rb
+1
-0
spec/serializers/ci/pipeline_entity_spec.rb
spec/serializers/ci/pipeline_entity_spec.rb
+3
-0
spec/serializers/container_repository_entity_spec.rb
spec/serializers/container_repository_entity_spec.rb
+1
-0
spec/serializers/container_tag_entity_spec.rb
spec/serializers/container_tag_entity_spec.rb
+1
-0
spec/serializers/deployment_serializer_spec.rb
spec/serializers/deployment_serializer_spec.rb
+1
-0
spec/serializers/diff_file_entity_spec.rb
spec/serializers/diff_file_entity_spec.rb
+2
-0
spec/serializers/evidences/evidence_entity_spec.rb
spec/serializers/evidences/evidence_entity_spec.rb
+1
-0
spec/serializers/fork_namespace_entity_spec.rb
spec/serializers/fork_namespace_entity_spec.rb
+1
-0
spec/serializers/group_link/group_group_link_entity_spec.rb
spec/serializers/group_link/group_group_link_entity_spec.rb
+1
-0
spec/serializers/group_link/project_group_link_entity_spec.rb
.../serializers/group_link/project_group_link_entity_spec.rb
+1
-0
spec/serializers/issue_board_entity_spec.rb
spec/serializers/issue_board_entity_spec.rb
+1
-0
spec/serializers/member_entity_spec.rb
spec/serializers/member_entity_spec.rb
+1
-0
spec/serializers/member_user_entity_spec.rb
spec/serializers/member_user_entity_spec.rb
+1
-0
spec/serializers/merge_request_diff_entity_spec.rb
spec/serializers/merge_request_diff_entity_spec.rb
+1
-0
spec/serializers/merge_request_poll_cached_widget_entity_spec.rb
...rializers/merge_request_poll_cached_widget_entity_spec.rb
+1
-0
spec/serializers/merge_request_user_entity_spec.rb
spec/serializers/merge_request_user_entity_spec.rb
+1
-0
spec/serializers/namespace_basic_entity_spec.rb
spec/serializers/namespace_basic_entity_spec.rb
+1
-0
spec/serializers/pipeline_details_entity_spec.rb
spec/serializers/pipeline_details_entity_spec.rb
+1
-0
spec/serializers/project_import_entity_spec.rb
spec/serializers/project_import_entity_spec.rb
+1
-0
spec/serializers/project_serializer_spec.rb
spec/serializers/project_serializer_spec.rb
+1
-0
spec/serializers/review_app_setup_entity_spec.rb
spec/serializers/review_app_setup_entity_spec.rb
+1
-0
No files found.
.rubocop_manual_todo.yml
View file @
10fd73c4
...
@@ -905,28 +905,6 @@ RSpec/EmptyLineAfterFinalLetItBe:
...
@@ -905,28 +905,6 @@ RSpec/EmptyLineAfterFinalLetItBe:
-
spec/requests/lfs_http_spec.rb
-
spec/requests/lfs_http_spec.rb
-
spec/requests/product_analytics/collector_app_spec.rb
-
spec/requests/product_analytics/collector_app_spec.rb
-
spec/requests/rack_attack_global_spec.rb
-
spec/requests/rack_attack_global_spec.rb
-
spec/serializers/admin/user_entity_spec.rb
-
spec/serializers/ci/lint/result_serializer_spec.rb
-
spec/serializers/ci/pipeline_entity_spec.rb
-
spec/serializers/container_repository_entity_spec.rb
-
spec/serializers/container_tag_entity_spec.rb
-
spec/serializers/deployment_serializer_spec.rb
-
spec/serializers/diff_file_entity_spec.rb
-
spec/serializers/evidences/evidence_entity_spec.rb
-
spec/serializers/fork_namespace_entity_spec.rb
-
spec/serializers/group_link/group_group_link_entity_spec.rb
-
spec/serializers/group_link/project_group_link_entity_spec.rb
-
spec/serializers/issue_board_entity_spec.rb
-
spec/serializers/member_entity_spec.rb
-
spec/serializers/member_user_entity_spec.rb
-
spec/serializers/merge_request_diff_entity_spec.rb
-
spec/serializers/merge_request_poll_cached_widget_entity_spec.rb
-
spec/serializers/merge_request_user_entity_spec.rb
-
spec/serializers/namespace_basic_entity_spec.rb
-
spec/serializers/pipeline_details_entity_spec.rb
-
spec/serializers/project_import_entity_spec.rb
-
spec/serializers/project_serializer_spec.rb
-
spec/serializers/review_app_setup_entity_spec.rb
-
spec/services/admin/propagate_service_template_spec.rb
-
spec/services/admin/propagate_service_template_spec.rb
-
spec/services/alert_management/create_alert_issue_service_spec.rb
-
spec/services/alert_management/create_alert_issue_service_spec.rb
-
spec/services/audit_event_service_spec.rb
-
spec/services/audit_event_service_spec.rb
...
...
changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-serializers.yml
0 → 100644
View file @
10fd73c4
---
title
:
Fix EmptyLineAfterFinalLetItBe offenses in spec/serializers
merge_request
:
58406
author
:
Huzaifa Iftikhar @huzaifaiftikhar
type
:
fixed
spec/serializers/admin/user_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require "spec_helper"
...
@@ -4,6 +4,7 @@ require "spec_helper"
RSpec
.
describe
Admin
::
UserEntity
do
RSpec
.
describe
Admin
::
UserEntity
do
let_it_be
(
:user
)
{
build_stubbed
(
:user
)
}
let_it_be
(
:user
)
{
build_stubbed
(
:user
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:entity
)
do
let
(
:entity
)
do
...
...
spec/serializers/ci/lint/result_serializer_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
Ci
::
Lint
::
ResultSerializer
,
:aggregate_failures
do
RSpec
.
describe
Ci
::
Lint
::
ResultSerializer
,
:aggregate_failures
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:result
)
do
let
(
:result
)
do
Gitlab
::
Ci
::
Lint
Gitlab
::
Ci
::
Lint
.
new
(
project:
project
,
current_user:
project
.
owner
)
.
new
(
project:
project
,
current_user:
project
.
owner
)
...
...
spec/serializers/ci/pipeline_entity_spec.rb
View file @
10fd73c4
...
@@ -7,6 +7,7 @@ RSpec.describe Ci::PipelineEntity do
...
@@ -7,6 +7,7 @@ RSpec.describe Ci::PipelineEntity do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:request
)
{
double
(
'request'
,
current_user:
user
)
}
let
(
:request
)
{
double
(
'request'
,
current_user:
user
)
}
let
(
:entity
)
{
described_class
.
represent
(
pipeline
,
request:
request
)
}
let
(
:entity
)
{
described_class
.
represent
(
pipeline
,
request:
request
)
}
...
@@ -165,6 +166,7 @@ RSpec.describe Ci::PipelineEntity do
...
@@ -165,6 +166,7 @@ RSpec.describe Ci::PipelineEntity do
context
'when pipeline is detached merge request pipeline'
do
context
'when pipeline is detached merge request pipeline'
do
let_it_be
(
:merge_request
)
{
create
(
:merge_request
,
:with_detached_merge_request_pipeline
)
}
let_it_be
(
:merge_request
)
{
create
(
:merge_request
,
:with_detached_merge_request_pipeline
)
}
let
(
:project
)
{
merge_request
.
target_project
}
let
(
:project
)
{
merge_request
.
target_project
}
let
(
:pipeline
)
{
merge_request
.
pipelines_for_merge_request
.
first
}
let
(
:pipeline
)
{
merge_request
.
pipelines_for_merge_request
.
first
}
...
@@ -213,6 +215,7 @@ RSpec.describe Ci::PipelineEntity do
...
@@ -213,6 +215,7 @@ RSpec.describe Ci::PipelineEntity do
context
'when pipeline is merge request pipeline'
do
context
'when pipeline is merge request pipeline'
do
let_it_be
(
:merge_request
)
{
create
(
:merge_request
,
:with_merge_request_pipeline
,
merge_sha:
'abc'
)
}
let_it_be
(
:merge_request
)
{
create
(
:merge_request
,
:with_merge_request_pipeline
,
merge_sha:
'abc'
)
}
let
(
:project
)
{
merge_request
.
target_project
}
let
(
:project
)
{
merge_request
.
target_project
}
let
(
:pipeline
)
{
merge_request
.
pipelines_for_merge_request
.
first
}
let
(
:pipeline
)
{
merge_request
.
pipelines_for_merge_request
.
first
}
...
...
spec/serializers/container_repository_entity_spec.rb
View file @
10fd73c4
...
@@ -6,6 +6,7 @@ RSpec.describe ContainerRepositoryEntity do
...
@@ -6,6 +6,7 @@ RSpec.describe ContainerRepositoryEntity do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:repository
)
{
create
(
:container_repository
,
project:
project
)
}
let_it_be
(
:repository
)
{
create
(
:container_repository
,
project:
project
)
}
let
(
:entity
)
{
described_class
.
new
(
repository
,
request:
request
)
}
let
(
:entity
)
{
described_class
.
new
(
repository
,
request:
request
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:request
)
{
double
(
'request'
)
}
...
...
spec/serializers/container_tag_entity_spec.rb
View file @
10fd73c4
...
@@ -6,6 +6,7 @@ RSpec.describe ContainerTagEntity do
...
@@ -6,6 +6,7 @@ RSpec.describe ContainerTagEntity do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:repository
)
{
create
(
:container_repository
,
name:
'image'
,
project:
project
)
}
let_it_be
(
:repository
)
{
create
(
:container_repository
,
name:
'image'
,
project:
project
)
}
let
(
:entity
)
{
described_class
.
new
(
tag
,
request:
request
)
}
let
(
:entity
)
{
described_class
.
new
(
tag
,
request:
request
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:tag
)
{
repository
.
tag
(
'test'
)
}
let
(
:tag
)
{
repository
.
tag
(
'test'
)
}
...
...
spec/serializers/deployment_serializer_spec.rb
View file @
10fd73c4
...
@@ -5,6 +5,7 @@ require 'spec_helper'
...
@@ -5,6 +5,7 @@ require 'spec_helper'
RSpec
.
describe
DeploymentSerializer
do
RSpec
.
describe
DeploymentSerializer
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
,
email:
project
.
commit
.
author_email
)
}
let_it_be
(
:user
)
{
create
(
:user
,
email:
project
.
commit
.
author_email
)
}
let
(
:resource
)
{
create
(
:deployment
,
project:
project
,
sha:
project
.
commit
.
id
)
}
let
(
:resource
)
{
create
(
:deployment
,
project:
project
,
sha:
project
.
commit
.
id
)
}
let
(
:serializer
)
{
described_class
.
new
(
request
)
}
let
(
:serializer
)
{
described_class
.
new
(
request
)
}
...
...
spec/serializers/diff_file_entity_spec.rb
View file @
10fd73c4
...
@@ -6,6 +6,7 @@ RSpec.describe DiffFileEntity do
...
@@ -6,6 +6,7 @@ RSpec.describe DiffFileEntity do
include
RepoHelpers
include
RepoHelpers
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:repository
)
{
project
.
repository
}
let
(
:repository
)
{
project
.
repository
}
let
(
:commit
)
{
project
.
commit
(
sample_commit
.
id
)
}
let
(
:commit
)
{
project
.
commit
(
sample_commit
.
id
)
}
let
(
:diff_refs
)
{
commit
.
diff_refs
}
let
(
:diff_refs
)
{
commit
.
diff_refs
}
...
@@ -22,6 +23,7 @@ RSpec.describe DiffFileEntity do
...
@@ -22,6 +23,7 @@ RSpec.describe DiffFileEntity do
context
'when there is a merge request'
do
context
'when there is a merge request'
do
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
(
:user
)
{
create
(
:user
)
}
let
(
:user
)
{
create
(
:user
)
}
let
(
:code_navigation_path
)
{
Gitlab
::
CodeNavigationPath
.
new
(
project
,
project
.
commit
.
sha
)
}
let
(
:code_navigation_path
)
{
Gitlab
::
CodeNavigationPath
.
new
(
project
,
project
.
commit
.
sha
)
}
let
(
:request
)
{
EntityRequest
.
new
(
project:
project
,
current_user:
user
)
}
let
(
:request
)
{
EntityRequest
.
new
(
project:
project
,
current_user:
user
)
}
...
...
spec/serializers/evidences/evidence_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
Evidences
::
EvidenceEntity
do
RSpec
.
describe
Evidences
::
EvidenceEntity
do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let
(
:release
)
{
create
(
:release
,
project:
project
)
}
let
(
:release
)
{
create
(
:release
,
project:
project
)
}
let
(
:evidence
)
{
build
(
:evidence
,
release:
release
)
}
let
(
:evidence
)
{
build
(
:evidence
,
release:
release
)
}
let
(
:schema_file
)
{
'evidences/evidence'
}
let
(
:schema_file
)
{
'evidences/evidence'
}
...
...
spec/serializers/fork_namespace_entity_spec.rb
View file @
10fd73c4
...
@@ -9,6 +9,7 @@ RSpec.describe ForkNamespaceEntity do
...
@@ -9,6 +9,7 @@ RSpec.describe ForkNamespaceEntity do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:namespace
)
{
create
(
:group
,
:with_avatar
,
description:
'test'
)
}
let_it_be
(
:namespace
)
{
create
(
:group
,
:with_avatar
,
description:
'test'
)
}
let
(
:memberships
)
do
let
(
:memberships
)
do
user
.
members
.
index_by
(
&
:source_id
)
user
.
members
.
index_by
(
&
:source_id
)
end
end
...
...
spec/serializers/group_link/group_group_link_entity_spec.rb
View file @
10fd73c4
...
@@ -6,6 +6,7 @@ RSpec.describe GroupLink::GroupGroupLinkEntity do
...
@@ -6,6 +6,7 @@ RSpec.describe GroupLink::GroupGroupLinkEntity do
include_context
'group_group_link'
include_context
'group_group_link'
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let
(
:entity
)
{
described_class
.
new
(
group_group_link
)
}
let
(
:entity
)
{
described_class
.
new
(
group_group_link
)
}
before
do
before
do
...
...
spec/serializers/group_link/project_group_link_entity_spec.rb
View file @
10fd73c4
...
@@ -5,6 +5,7 @@ require 'spec_helper'
...
@@ -5,6 +5,7 @@ require 'spec_helper'
RSpec
.
describe
GroupLink
::
ProjectGroupLinkEntity
do
RSpec
.
describe
GroupLink
::
ProjectGroupLinkEntity
do
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let_it_be
(
:project_group_link
)
{
create
(
:project_group_link
)
}
let_it_be
(
:project_group_link
)
{
create
(
:project_group_link
)
}
let
(
:entity
)
{
described_class
.
new
(
project_group_link
)
}
let
(
:entity
)
{
described_class
.
new
(
project_group_link
)
}
before
do
before
do
...
...
spec/serializers/issue_board_entity_spec.rb
View file @
10fd73c4
...
@@ -8,6 +8,7 @@ RSpec.describe IssueBoardEntity do
...
@@ -8,6 +8,7 @@ RSpec.describe IssueBoardEntity do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:milestone
)
{
create
(
:milestone
,
project:
project
)
}
let_it_be
(
:milestone
)
{
create
(
:milestone
,
project:
project
)
}
let_it_be
(
:label
)
{
create
(
:label
,
project:
project
,
title:
'Test Label'
)
}
let_it_be
(
:label
)
{
create
(
:label
,
project:
project
,
title:
'Test Label'
)
}
let
(
:request
)
{
double
(
'request'
,
current_user:
user
)
}
let
(
:request
)
{
double
(
'request'
,
current_user:
user
)
}
subject
{
described_class
.
new
(
resource
,
request:
request
).
as_json
}
subject
{
described_class
.
new
(
resource
,
request:
request
).
as_json
}
...
...
spec/serializers/member_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
MemberEntity
do
RSpec
.
describe
MemberEntity
do
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let_it_be
(
:current_user
)
{
create
(
:user
)
}
let
(
:entity
)
{
described_class
.
new
(
member
,
{
current_user:
current_user
,
group:
group
,
source:
source
})
}
let
(
:entity
)
{
described_class
.
new
(
member
,
{
current_user:
current_user
,
group:
group
,
source:
source
})
}
let
(
:entity_hash
)
{
entity
.
as_json
}
let
(
:entity_hash
)
{
entity
.
as_json
}
...
...
spec/serializers/member_user_entity_spec.rb
View file @
10fd73c4
...
@@ -6,6 +6,7 @@ RSpec.describe MemberUserEntity do
...
@@ -6,6 +6,7 @@ RSpec.describe MemberUserEntity do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:emoji
)
{
'slight_smile'
}
let_it_be
(
:emoji
)
{
'slight_smile'
}
let_it_be
(
:user_status
)
{
create
(
:user_status
,
user:
user
,
emoji:
emoji
)
}
let_it_be
(
:user_status
)
{
create
(
:user_status
,
user:
user
,
emoji:
emoji
)
}
let
(
:entity
)
{
described_class
.
new
(
user
)
}
let
(
:entity
)
{
described_class
.
new
(
user
)
}
let
(
:entity_hash
)
{
entity
.
as_json
}
let
(
:entity_hash
)
{
entity
.
as_json
}
...
...
spec/serializers/merge_request_diff_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
MergeRequestDiffEntity
do
RSpec
.
describe
MergeRequestDiffEntity
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:request
)
{
EntityRequest
.
new
(
project:
project
)
}
let
(
:request
)
{
EntityRequest
.
new
(
project:
project
)
}
let
(
:merge_request
)
{
create
(
:merge_request_with_diffs
,
target_project:
project
,
source_project:
project
)
}
let
(
:merge_request
)
{
create
(
:merge_request_with_diffs
,
target_project:
project
,
source_project:
project
)
}
let
(
:merge_request_diffs
)
{
merge_request
.
merge_request_diffs
}
let
(
:merge_request_diffs
)
{
merge_request
.
merge_request_diffs
}
...
...
spec/serializers/merge_request_poll_cached_widget_entity_spec.rb
View file @
10fd73c4
...
@@ -8,6 +8,7 @@ RSpec.describe MergeRequestPollCachedWidgetEntity do
...
@@ -8,6 +8,7 @@ RSpec.describe MergeRequestPollCachedWidgetEntity do
let_it_be
(
:project
,
refind:
true
)
{
create
:project
,
:repository
}
let_it_be
(
:project
,
refind:
true
)
{
create
:project
,
:repository
}
let_it_be
(
:resource
,
refind:
true
)
{
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)
}
let_it_be
(
:resource
,
refind:
true
)
{
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:pipeline
)
{
create
(
:ci_empty_pipeline
,
project:
project
)
}
let
(
:pipeline
)
{
create
(
:ci_empty_pipeline
,
project:
project
)
}
let
(
:request
)
{
double
(
'request'
,
current_user:
user
,
project:
project
)
}
let
(
:request
)
{
double
(
'request'
,
current_user:
user
,
project:
project
)
}
...
...
spec/serializers/merge_request_user_entity_spec.rb
View file @
10fd73c4
...
@@ -5,6 +5,7 @@ require 'spec_helper'
...
@@ -5,6 +5,7 @@ require 'spec_helper'
RSpec
.
describe
MergeRequestUserEntity
do
RSpec
.
describe
MergeRequestUserEntity
do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:merge_request
)
{
create
(
:merge_request
)
}
let_it_be
(
:merge_request
)
{
create
(
:merge_request
)
}
let
(
:request
)
{
EntityRequest
.
new
(
project:
merge_request
.
target_project
,
current_user:
user
)
}
let
(
:request
)
{
EntityRequest
.
new
(
project:
merge_request
.
target_project
,
current_user:
user
)
}
let
(
:entity
)
do
let
(
:entity
)
do
...
...
spec/serializers/namespace_basic_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
NamespaceBasicEntity
do
RSpec
.
describe
NamespaceBasicEntity
do
let_it_be
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let
(
:entity
)
do
let
(
:entity
)
do
described_class
.
represent
(
group
)
described_class
.
represent
(
group
)
end
end
...
...
spec/serializers/pipeline_details_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
PipelineDetailsEntity
do
RSpec
.
describe
PipelineDetailsEntity
do
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:request
)
{
double
(
'request'
)
}
let
(
:entity
)
do
let
(
:entity
)
do
...
...
spec/serializers/project_import_entity_spec.rb
View file @
10fd73c4
...
@@ -6,6 +6,7 @@ RSpec.describe ProjectImportEntity do
...
@@ -6,6 +6,7 @@ RSpec.describe ProjectImportEntity do
include
ImportHelper
include
ImportHelper
let_it_be
(
:project
)
{
create
(
:project
,
import_status: :started
,
import_source:
'namespace/project'
)
}
let_it_be
(
:project
)
{
create
(
:project
,
import_status: :started
,
import_source:
'namespace/project'
)
}
let
(
:provider_url
)
{
'https://provider.com'
}
let
(
:provider_url
)
{
'https://provider.com'
}
let
(
:entity
)
{
described_class
.
represent
(
project
,
provider_url:
provider_url
)
}
let
(
:entity
)
{
described_class
.
represent
(
project
,
provider_url:
provider_url
)
}
...
...
spec/serializers/project_serializer_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
ProjectSerializer
do
RSpec
.
describe
ProjectSerializer
do
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let
(
:provider_url
)
{
'http://provider.com'
}
let
(
:provider_url
)
{
'http://provider.com'
}
context
'when serializer option is :import'
do
context
'when serializer option is :import'
do
...
...
spec/serializers/review_app_setup_entity_spec.rb
View file @
10fd73c4
...
@@ -4,6 +4,7 @@ require 'spec_helper'
...
@@ -4,6 +4,7 @@ require 'spec_helper'
RSpec
.
describe
ReviewAppSetupEntity
do
RSpec
.
describe
ReviewAppSetupEntity
do
let_it_be
(
:user
)
{
create
(
:admin
)
}
let_it_be
(
:user
)
{
create
(
:admin
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:presenter
)
{
ProjectPresenter
.
new
(
project
,
current_user:
user
)
}
let
(
:presenter
)
{
ProjectPresenter
.
new
(
project
,
current_user:
user
)
}
let
(
:entity
)
{
described_class
.
new
(
presenter
)
}
let
(
:entity
)
{
described_class
.
new
(
presenter
)
}
...
...
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