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
cbb9492a
Commit
cbb9492a
authored
Jan 14, 2020
by
Vitali Tatarintev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change set to let_it_be in ee/spec/services
Contributes to a removal of rspec-set gem
parent
6ac86fea
Changes
54
Hide whitespace changes
Inline
Side-by-side
Showing
54 changed files
with
118 additions
and
118 deletions
+118
-118
ee/spec/services/auto_merge/add_to_merge_train_when_pipeline_succeeds_service_spec.rb
...add_to_merge_train_when_pipeline_succeeds_service_spec.rb
+2
-2
ee/spec/services/auto_merge/merge_train_service_spec.rb
ee/spec/services/auto_merge/merge_train_service_spec.rb
+2
-2
ee/spec/services/ci/compare_metrics_reports_service_spec.rb
ee/spec/services/ci/compare_metrics_reports_service_spec.rb
+1
-1
ee/spec/services/ci/create_cross_project_pipeline_service_spec.rb
...services/ci/create_cross_project_pipeline_service_spec.rb
+2
-2
ee/spec/services/ci/create_pipeline_service/needs_spec.rb
ee/spec/services/ci/create_pipeline_service/needs_spec.rb
+1
-1
ee/spec/services/ci/create_pipeline_service_spec.rb
ee/spec/services/ci/create_pipeline_service_spec.rb
+5
-5
ee/spec/services/ci/create_web_ide_terminal_service_spec.rb
ee/spec/services/ci/create_web_ide_terminal_service_spec.rb
+2
-2
ee/spec/services/ci/process_pipeline_service_spec.rb
ee/spec/services/ci/process_pipeline_service_spec.rb
+4
-4
ee/spec/services/ci/register_job_service_spec.rb
ee/spec/services/ci/register_job_service_spec.rb
+1
-1
ee/spec/services/ci/web_ide_config_service_spec.rb
ee/spec/services/ci/web_ide_config_service_spec.rb
+2
-2
ee/spec/services/clusters/applications/prometheus_config_service_spec.rb
...s/clusters/applications/prometheus_config_service_spec.rb
+3
-3
ee/spec/services/design_management/delete_designs_service_spec.rb
...services/design_management/delete_designs_service_spec.rb
+3
-3
ee/spec/services/design_management/design_user_notes_count_service_spec.rb
...design_management/design_user_notes_count_service_spec.rb
+1
-1
ee/spec/services/ee/git/branch_push_service_spec.rb
ee/spec/services/ee/git/branch_push_service_spec.rb
+7
-7
ee/spec/services/ee/merge_requests/base_service_spec.rb
ee/spec/services/ee/merge_requests/base_service_spec.rb
+1
-1
ee/spec/services/ee/notes/create_service_spec.rb
ee/spec/services/ee/notes/create_service_spec.rb
+3
-3
ee/spec/services/ee/notification_service_spec.rb
ee/spec/services/ee/notification_service_spec.rb
+7
-7
ee/spec/services/ee/resource_events/merge_into_notes_service_spec.rb
...vices/ee/resource_events/merge_into_notes_service_spec.rb
+10
-10
ee/spec/services/geo/cache_invalidation_event_store_spec.rb
ee/spec/services/geo/cache_invalidation_event_store_spec.rb
+1
-1
ee/spec/services/geo/container_repository_sync_service_spec.rb
...ec/services/geo/container_repository_sync_service_spec.rb
+1
-1
ee/spec/services/geo/container_repository_updated_event_store_spec.rb
...ices/geo/container_repository_updated_event_store_spec.rb
+1
-1
ee/spec/services/geo/design_repository_sync_service_spec.rb
ee/spec/services/geo/design_repository_sync_service_spec.rb
+3
-3
ee/spec/services/geo/file_download_service_spec.rb
ee/spec/services/geo/file_download_service_spec.rb
+2
-2
ee/spec/services/geo/file_registry_removal_service_spec.rb
ee/spec/services/geo/file_registry_removal_service_spec.rb
+2
-2
ee/spec/services/geo/file_upload_service_spec.rb
ee/spec/services/geo/file_upload_service_spec.rb
+1
-1
ee/spec/services/geo/hashed_storage_attachments_event_store_spec.rb
...rvices/geo/hashed_storage_attachments_event_store_spec.rb
+1
-1
ee/spec/services/geo/hashed_storage_migrated_event_store_spec.rb
.../services/geo/hashed_storage_migrated_event_store_spec.rb
+1
-1
ee/spec/services/geo/job_artifact_deleted_event_store_spec.rb
...pec/services/geo/job_artifact_deleted_event_store_spec.rb
+1
-1
ee/spec/services/geo/lfs_object_deleted_event_store_spec.rb
ee/spec/services/geo/lfs_object_deleted_event_store_spec.rb
+1
-1
ee/spec/services/geo/metrics_update_service_spec.rb
ee/spec/services/geo/metrics_update_service_spec.rb
+3
-3
ee/spec/services/geo/node_status_post_service_spec.rb
ee/spec/services/geo/node_status_post_service_spec.rb
+2
-2
ee/spec/services/geo/node_update_service_spec.rb
ee/spec/services/geo/node_update_service_spec.rb
+1
-1
ee/spec/services/geo/project_housekeeping_service_spec.rb
ee/spec/services/geo/project_housekeeping_service_spec.rb
+1
-1
ee/spec/services/geo/repository_created_event_store_spec.rb
ee/spec/services/geo/repository_created_event_store_spec.rb
+2
-2
ee/spec/services/geo/repository_deleted_event_store_spec.rb
ee/spec/services/geo/repository_deleted_event_store_spec.rb
+2
-2
ee/spec/services/geo/repository_destroy_service_spec.rb
ee/spec/services/geo/repository_destroy_service_spec.rb
+1
-1
ee/spec/services/geo/repository_renamed_event_store_spec.rb
ee/spec/services/geo/repository_renamed_event_store_spec.rb
+2
-2
ee/spec/services/geo/repository_sync_service_spec.rb
ee/spec/services/geo/repository_sync_service_spec.rb
+3
-3
ee/spec/services/geo/repository_updated_event_store_spec.rb
ee/spec/services/geo/repository_updated_event_store_spec.rb
+2
-2
ee/spec/services/geo/repository_updated_service_spec.rb
ee/spec/services/geo/repository_updated_service_spec.rb
+4
-4
ee/spec/services/geo/reset_checksum_event_store_spec.rb
ee/spec/services/geo/reset_checksum_event_store_spec.rb
+2
-2
ee/spec/services/geo/upload_deleted_event_store_spec.rb
ee/spec/services/geo/upload_deleted_event_store_spec.rb
+1
-1
ee/spec/services/geo/wiki_sync_service_spec.rb
ee/spec/services/geo/wiki_sync_service_spec.rb
+3
-3
ee/spec/services/jira_connect/sync_service_spec.rb
ee/spec/services/jira_connect/sync_service_spec.rb
+1
-1
ee/spec/services/licenses/destroy_service_spec.rb
ee/spec/services/licenses/destroy_service_spec.rb
+1
-1
ee/spec/services/merge_trains/create_pipeline_service_spec.rb
...pec/services/merge_trains/create_pipeline_service_spec.rb
+1
-1
ee/spec/services/merge_trains/refresh_merge_request_service_spec.rb
...rvices/merge_trains/refresh_merge_request_service_spec.rb
+2
-2
ee/spec/services/merge_trains/refresh_merge_requests_service_spec.rb
...vices/merge_trains/refresh_merge_requests_service_spec.rb
+2
-2
ee/spec/services/metrics/dashboard/cluster_dashboard_service_spec.rb
...vices/metrics/dashboard/cluster_dashboard_service_spec.rb
+4
-4
ee/spec/services/process_github_pull_request_event_service_spec.rb
...ervices/process_github_pull_request_event_service_spec.rb
+2
-2
ee/spec/services/search/global_service_spec.rb
ee/spec/services/search/global_service_spec.rb
+1
-1
ee/spec/services/search/group_service_spec.rb
ee/spec/services/search/group_service_spec.rb
+1
-1
ee/spec/services/search/project_service_spec.rb
ee/spec/services/search/project_service_spec.rb
+1
-1
ee/spec/services/security/report_fetch_service_spec.rb
ee/spec/services/security/report_fetch_service_spec.rb
+1
-1
No files found.
ee/spec/services/auto_merge/add_to_merge_train_when_pipeline_succeeds_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,8 +3,8 @@
require
'spec_helper'
describe
AutoMerge
::
AddToMergeTrainWhenPipelineSucceedsService
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
,
reload:
true
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
user
)
}
let
(
:merge_request
)
do
...
...
ee/spec/services/auto_merge/merge_train_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,8 +5,8 @@ require 'spec_helper'
describe
AutoMerge
::
MergeTrainService
do
include
ExclusiveLeaseHelpers
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
user
,
params
)
}
let
(
:params
)
{
{}
}
...
...
ee/spec/services/ci/compare_metrics_reports_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
describe
Ci
::
CompareMetricsReportsService
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:service
)
{
described_class
.
new
(
project
)
}
before
do
...
...
ee/spec/services/ci/create_cross_project_pipeline_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,9 +3,9 @@
require
'spec_helper'
describe
Ci
::
CreateCrossProjectPipelineService
,
'#execute'
do
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:upstream_project
)
{
create
(
:project
,
:repository
)
}
set
(
:downstream_project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:downstream_project
)
{
create
(
:project
,
:repository
)
}
let!
(
:upstream_pipeline
)
do
create
(
:ci_pipeline
,
:running
,
project:
upstream_project
)
...
...
ee/spec/services/ci/create_pipeline_service/needs_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Ci
::
CreatePipelineService
do
subject
(
:execute
)
{
service
.
execute
(
:push
)
}
set
(
:downstream_project
)
{
create
(
:project
,
name:
'project'
,
namespace:
create
(
:namespace
,
name:
'some'
))
}
let_it_be
(
:downstream_project
)
{
create
(
:project
,
name:
'project'
,
namespace:
create
(
:namespace
,
name:
'some'
))
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
create
(
:admin
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
user
,
{
ref:
'refs/heads/master'
})
}
...
...
ee/spec/services/ci/create_pipeline_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,11 +3,11 @@
require
'spec_helper'
describe
Ci
::
CreatePipelineService
,
'#execute'
do
set
(
:namespace
)
{
create
(
:namespace
)
}
set
(
:gold_plan
)
{
create
(
:gold_plan
)
}
set
(
:plan_limits
)
{
create
(
:plan_limits
,
plan:
gold_plan
)
}
set
(
:project
)
{
create
(
:project
,
:repository
,
namespace:
namespace
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:namespace
)
{
create
(
:namespace
)
}
let_it_be
(
:gold_plan
)
{
create
(
:gold_plan
)
}
let_it_be
(
:plan_limits
)
{
create
(
:plan_limits
,
plan:
gold_plan
)
}
let_it_be
(
:project
,
reload:
true
)
{
create
(
:project
,
:repository
,
namespace:
namespace
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:ref_name
)
{
'master'
}
let
(
:service
)
do
...
...
ee/spec/services/ci/create_web_ide_terminal_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,8 +3,8 @@
require
'spec_helper'
describe
Ci
::
CreateWebIdeTerminalService
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:ref
)
{
'master'
}
before
do
...
...
ee/spec/services/ci/process_pipeline_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,11 +3,11 @@
require
'spec_helper'
describe
Ci
::
ProcessPipelineService
,
'#execute'
do
set
(
:user
)
{
create
(
:user
)
}
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:downstream
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:downstream
)
{
create
(
:project
,
:repository
)
}
set
(
:pipeline
)
do
let_it_be
(
:pipeline
)
do
create
(
:ci_empty_pipeline
,
ref:
'master'
,
project:
project
,
user:
user
)
end
...
...
ee/spec/services/ci/register_job_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
describe
Ci
::
RegisterJobService
do
set
(
:shared_runner
)
{
create
(
:ci_runner
,
:instance
)
}
let_it_be
(
:shared_runner
)
{
create
(
:ci_runner
,
:instance
)
}
let!
(
:project
)
{
create
:project
,
shared_runners_enabled:
true
}
let!
(
:pipeline
)
{
create
:ci_empty_pipeline
,
project:
project
}
let!
(
:pending_build
)
{
create
:ci_build
,
pipeline:
pipeline
}
...
...
ee/spec/services/ci/web_ide_config_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,8 +3,8 @@
require
'spec_helper'
describe
Ci
::
WebIdeConfigService
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:sha
)
{
'sha'
}
describe
'#execute'
do
...
...
ee/spec/services/clusters/applications/prometheus_config_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,9 +5,9 @@ require 'spec_helper'
describe
Clusters
::
Applications
::
PrometheusConfigService
do
include
Gitlab
::
Routing
.
url_helpers
set
(
:project
)
{
create
(
:project
)
}
set
(
:production
)
{
create
(
:environment
,
project:
project
)
}
set
(
:cluster
)
{
create
(
:cluster
,
:provided_by_user
,
projects:
[
project
])
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:production
)
{
create
(
:environment
,
project:
project
)
}
let_it_be
(
:cluster
)
{
create
(
:cluster
,
:provided_by_user
,
projects:
[
project
])
}
let
(
:application
)
do
create
(
:clusters_applications_prometheus
,
:installed
,
cluster:
cluster
)
...
...
ee/spec/services/design_management/delete_designs_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,9 +3,9 @@ require 'spec_helper'
describe
DesignManagement
::
DeleteDesignsService
do
include
DesignManagementTestHelpers
set
(
:project
)
{
create
(
:project
)
}
set
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:designs
)
{
create_designs
}
subject
(
:service
)
{
described_class
.
new
(
project
,
user
,
issue:
issue
,
designs:
designs
)
}
...
...
ee/spec/services/design_management/design_user_notes_count_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
describe
DesignManagement
::
DesignUserNotesCountService
,
:use_clean_rails_memory_store_caching
do
set
(
:design
)
{
create
(
:design
,
:with_file
)
}
let_it_be
(
:design
)
{
create
(
:design
,
:with_file
)
}
subject
{
described_class
.
new
(
design
)
}
...
...
ee/spec/services/ee/git/branch_push_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,11 +5,11 @@ require 'spec_helper'
describe
Git
::
BranchPushService
do
include
RepoHelpers
set
(
:user
)
{
create
(
:user
)
}
let
(
:blankrev
)
{
Gitlab
::
Git
::
BLANK_SHA
}
let
(
:oldrev
)
{
sample_commit
.
parent_id
}
let
(
:newrev
)
{
sample_commit
.
id
}
let
(
:ref
)
{
'refs/heads/master'
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:blankrev
)
{
Gitlab
::
Git
::
BLANK_SHA
}
let
(
:oldrev
)
{
sample_commit
.
parent_id
}
let
(
:newrev
)
{
sample_commit
.
id
}
let
(
:ref
)
{
'refs/heads/master'
}
let
(
:params
)
do
{
change:
{
oldrev:
oldrev
,
newrev:
newrev
,
ref:
ref
}
}
...
...
@@ -20,7 +20,7 @@ describe Git::BranchPushService do
end
context
'with pull project'
do
set
(
:project
)
{
create
(
:project
,
:repository
,
:mirror
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
,
:mirror
)
}
before
do
allow
(
project
.
repository
).
to
receive
(
:commit
).
and_call_original
...
...
@@ -152,7 +152,7 @@ describe Git::BranchPushService do
end
context
'Jira Connect hooks'
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:branch_to_sync
)
{
nil
}
let
(
:commits_to_sync
)
{
[]
}
...
...
ee/spec/services/ee/merge_requests/base_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
MergeRequests
::
BaseService
do
include
ProjectForksHelper
set
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:title
)
{
'Awesome merge_request'
}
let
(
:params
)
do
{
...
...
ee/spec/services/ee/notes/create_service_spec.rb
View file @
cbb9492a
...
...
@@ -4,9 +4,9 @@ require 'spec_helper'
describe
Notes
::
CreateService
do
context
'notes for designs'
do
set
(
:design
)
{
create
(
:design
,
:with_file
)
}
set
(
:project
)
{
design
.
project
}
set
(
:user
)
{
project
.
owner
}
let_it_be
(
:design
)
{
create
(
:design
,
:with_file
)
}
let_it_be
(
:project
)
{
design
.
project
}
let_it_be
(
:user
)
{
project
.
owner
}
subject
(
:service
)
{
described_class
.
new
(
project
,
user
,
opts
)
}
...
...
ee/spec/services/ee/notification_service_spec.rb
View file @
cbb9492a
...
...
@@ -12,11 +12,11 @@ describe EE::NotificationService, :mailer do
let
(
:mailer
)
{
double
(
deliver_later:
true
)
}
context
'when notified of a new design diff note'
do
set
(
:design
)
{
create
(
:design
,
:with_file
)
}
set
(
:project
)
{
design
.
project
}
set
(
:dev
)
{
create
(
:user
)
}
set
(
:stranger
)
{
create
(
:user
)
}
set
(
:note
)
do
let_it_be
(
:design
)
{
create
(
:design
,
:with_file
)
}
let_it_be
(
:project
)
{
design
.
project
}
let_it_be
(
:dev
)
{
create
(
:user
)
}
let_it_be
(
:stranger
)
{
create
(
:user
)
}
let_it_be
(
:note
)
do
create
(
:diff_note_on_design
,
noteable:
design
,
project:
project
,
...
...
@@ -412,8 +412,8 @@ describe EE::NotificationService, :mailer do
end
describe
'epics'
do
set
(
:group
)
{
create
(
:group
,
:private
)
}
set
(
:epic
)
{
create
(
:epic
,
group:
group
)
}
let_it_be
(
:group
)
{
create
(
:group
,
:private
)
}
let_it_be
(
:epic
)
{
create
(
:epic
,
group:
group
)
}
around
do
|
example
|
perform_enqueued_jobs
do
...
...
ee/spec/services/ee/resource_events/merge_into_notes_service_spec.rb
View file @
cbb9492a
...
...
@@ -16,16 +16,16 @@ describe ResourceEvents::MergeIntoNotesService do
create
(
:resource_weight_event
,
event_params
.
merge
(
params
))
end
set
(
:project
)
{
create
(
:project
)
}
set
(
:user
)
{
create
(
:user
)
}
set
(
:resource
)
{
create
(
:issue
,
project:
project
)
}
set
(
:label
)
{
create
(
:label
,
project:
project
)
}
set
(
:label2
)
{
create
(
:label
,
project:
project
)
}
set
(
:scoped_label_group1_1
)
{
create
(
:label
,
project:
project
,
title:
'key::value'
)
}
set
(
:scoped_label_group1_2
)
{
create
(
:label
,
project:
project
,
title:
'key::value2'
)
}
set
(
:scoped_label_group2_1
)
{
create
(
:label
,
project:
project
,
title:
'key2::value'
)
}
set
(
:scoped_label_group2_2
)
{
create
(
:label
,
project:
project
,
title:
'key2::value2'
)
}
set
(
:scoped_label_group3_1
)
{
create
(
:label
,
project:
project
,
title:
'key3::value'
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:resource
)
{
create
(
:issue
,
project:
project
)
}
let_it_be
(
:label
)
{
create
(
:label
,
project:
project
)
}
let_it_be
(
:label2
)
{
create
(
:label
,
project:
project
)
}
let_it_be
(
:scoped_label_group1_1
)
{
create
(
:label
,
project:
project
,
title:
'key::value'
)
}
let_it_be
(
:scoped_label_group1_2
)
{
create
(
:label
,
project:
project
,
title:
'key::value2'
)
}
let_it_be
(
:scoped_label_group2_1
)
{
create
(
:label
,
project:
project
,
title:
'key2::value'
)
}
let_it_be
(
:scoped_label_group2_2
)
{
create
(
:label
,
project:
project
,
title:
'key2::value2'
)
}
let_it_be
(
:scoped_label_group3_1
)
{
create
(
:label
,
project:
project
,
title:
'key3::value'
)
}
let
(
:time
)
{
Time
.
now
}
describe
'#execute'
do
...
...
ee/spec/services/geo/cache_invalidation_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
CacheInvalidationEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:cache_key
)
{
'cache-key'
}
...
...
ee/spec/services/geo/container_repository_sync_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,7 +6,7 @@ describe Geo::ContainerRepositorySyncService, :geo do
include
::
EE
::
GeoHelpers
include
ExclusiveLeaseHelpers
set
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
let
(
:registry
)
{
create
(
:container_repository_registry
,
:sync_started
)
}
let
(
:container_repository
)
{
registry
.
container_repository
}
...
...
ee/spec/services/geo/container_repository_updated_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
ContainerRepositoryUpdatedEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:container_repository
)
{
create
:container_repository
}
...
...
ee/spec/services/geo/design_repository_sync_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,9 +6,9 @@ describe Geo::DesignRepositorySyncService do
include
::
EE
::
GeoHelpers
include
ExclusiveLeaseHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
set
(
:project
)
{
create
(
:project_empty_repo
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project_empty_repo
)
}
let
(
:repository
)
{
project
.
design_repository
}
let
(
:lease_key
)
{
"geo_sync_service:design:
#{
project
.
id
}
"
}
...
...
ee/spec/services/geo/file_download_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,8 +6,8 @@ describe Geo::FileDownloadService do
include
::
EE
::
GeoHelpers
include
ExclusiveLeaseHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
before
do
stub_current_geo_node
(
secondary
)
...
...
ee/spec/services/geo/file_registry_removal_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,7 +6,7 @@ describe Geo::FileRegistryRemovalService do
include
::
EE
::
GeoHelpers
include
ExclusiveLeaseHelpers
set
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
before
do
stub_current_geo_node
(
secondary
)
...
...
@@ -190,7 +190,7 @@ describe Geo::FileRegistryRemovalService do
end
context
'with namespace_file'
do
set
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let
(
:file
)
{
fixture_file_upload
(
'spec/fixtures/dk.png'
,
'image/png'
)
}
let!
(
:upload
)
do
NamespaceFileUploader
.
new
(
group
).
store!
(
file
)
...
...
ee/spec/services/geo/file_upload_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
FileUploadService
do
include
EE
::
GeoHelpers
set
(
:node
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:node
)
{
create
(
:geo_node
,
:primary
)
}
let
(
:transfer_request
)
{
Gitlab
::
Geo
::
TransferRequest
.
new
(
request_data
)
}
let
(
:req_header
)
{
transfer_request
.
headers
[
'Authorization'
]
}
...
...
ee/spec/services/geo/hashed_storage_attachments_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
HashedStorageAttachmentsEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:project
)
{
create
(
:project
,
path:
'bar'
)
}
let
(
:attachments_event
)
{
build
(
:geo_hashed_storage_attachments_event
,
project:
project
)
}
...
...
ee/spec/services/geo/hashed_storage_migrated_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
HashedStorageMigratedEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:project
)
{
create
(
:project
,
:design_repo
,
path:
'bar'
)
}
let
(
:old_disk_path
)
{
"
#{
project
.
namespace
.
full_path
}
/foo"
}
...
...
ee/spec/services/geo/job_artifact_deleted_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
JobArtifactDeletedEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:job_artifact
)
{
create
(
:ci_job_artifact
,
:archive
)
}
...
...
ee/spec/services/geo/lfs_object_deleted_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
LfsObjectDeletedEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:lfs_object
)
{
create
(
:lfs_object
,
:with_file
,
oid:
'b68143e6463773b1b6c6fd009a76c32aeec041faff32ba2ed42fd7f708a00004'
)
}
...
...
ee/spec/services/geo/metrics_update_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,9 +5,9 @@ require 'spec_helper'
describe
Geo
::
MetricsUpdateService
,
:geo
,
:prometheus
do
include
::
EE
::
GeoHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
set
(
:another_secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:another_secondary
)
{
create
(
:geo_node
)
}
subject
{
described_class
.
new
}
...
...
ee/spec/services/geo/node_status_post_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,8 +6,8 @@ describe Geo::NodeStatusPostService, :geo do
include
::
EE
::
GeoHelpers
include
ApiHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
subject
{
described_class
.
new
}
...
...
ee/spec/services/geo/node_update_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
NodeUpdateService
do
include
EE
::
GeoHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:primary
,
reload:
true
)
{
create
(
:geo_node
,
:primary
)
}
let
(
:geo_node
)
{
create
(
:geo_node
)
}
let
(
:groups
)
{
create_list
(
:group
,
2
)
}
...
...
ee/spec/services/geo/project_housekeeping_service_spec.rb
View file @
cbb9492a
...
...
@@ -8,7 +8,7 @@ describe Geo::ProjectHousekeepingService do
subject
(
:service
)
{
described_class
.
new
(
project
)
}
set
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:registry
)
{
service
.
registry
}
before
do
...
...
ee/spec/services/geo/repository_created_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,8 +5,8 @@ require 'spec_helper'
describe
Geo
::
RepositoryCreatedEventStore
do
include
EE
::
GeoHelpers
set
(
:project
)
{
create
(
:project
)
}
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
subject
{
described_class
.
new
(
project
)
}
...
...
ee/spec/services/geo/repository_deleted_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,8 +5,8 @@ require 'spec_helper'
describe
Geo
::
RepositoryDeletedEventStore
do
include
EE
::
GeoHelpers
set
(
:project
)
{
create
(
:project
,
path:
'bar'
)
}
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project
,
path:
'bar'
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:project_id
)
{
project
.
id
}
let
(
:project_name
)
{
project
.
name
}
...
...
ee/spec/services/geo/repository_destroy_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
RepositoryDestroyService
do
include
::
EE
::
GeoHelpers
set
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
before
do
stub_current_geo_node
(
secondary
)
...
...
ee/spec/services/geo/repository_renamed_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,8 +5,8 @@ require 'spec_helper'
describe
Geo
::
RepositoryRenamedEventStore
do
include
EE
::
GeoHelpers
set
(
:project
)
{
create
(
:project
,
path:
'bar'
)
}
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project
,
path:
'bar'
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:old_path
)
{
'foo'
}
let
(
:old_path_with_namespace
)
{
"
#{
project
.
namespace
.
full_path
}
/foo"
}
...
...
ee/spec/services/geo/repository_sync_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,9 +6,9 @@ describe Geo::RepositorySyncService do
include
::
EE
::
GeoHelpers
include
ExclusiveLeaseHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
set
(
:project
)
{
create
(
:project_empty_repo
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project_empty_repo
)
}
let
(
:repository
)
{
project
.
repository
}
let
(
:lease_key
)
{
"geo_sync_service:repository:
#{
project
.
id
}
"
}
...
...
ee/spec/services/geo/repository_updated_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,8 +5,8 @@ require 'spec_helper'
describe
Geo
::
RepositoryUpdatedEventStore
do
include
EE
::
GeoHelpers
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:blankrev
)
{
Gitlab
::
Git
::
BLANK_SHA
}
let
(
:refs
)
{
[
'refs/heads/tést'
,
'refs/tags/tag'
]
}
...
...
ee/spec/services/geo/repository_updated_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,10 +5,10 @@ require 'spec_helper'
describe
Geo
::
RepositoryUpdatedService
do
include
::
EE
::
GeoHelpers
set
(
:project
)
{
create
(
:project
)
}
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
set
(
:repository_state
)
{
create
(
:repository_state
,
:repository_verified
,
:wiki_verified
,
project:
project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:repository_state
)
{
create
(
:repository_state
,
:repository_verified
,
:wiki_verified
,
project:
project
)
}
before
do
stub_current_geo_node
(
primary
)
...
...
ee/spec/services/geo/reset_checksum_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,8 +5,8 @@ require 'spec_helper'
describe
Geo
::
ResetChecksumEventStore
do
include
EE
::
GeoHelpers
set
(
:project
)
{
create
(
:project
)
}
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
subject
{
described_class
.
new
(
project
)
}
...
...
ee/spec/services/geo/upload_deleted_event_store_spec.rb
View file @
cbb9492a
...
...
@@ -5,7 +5,7 @@ require 'spec_helper'
describe
Geo
::
UploadDeletedEventStore
do
include
EE
::
GeoHelpers
set
(
:secondary_node
)
{
create
(
:geo_node
)
}
let_it_be
(
:secondary_node
)
{
create
(
:geo_node
)
}
let
(
:upload
)
{
create
(
:upload
)
}
...
...
ee/spec/services/geo/wiki_sync_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,9 +6,9 @@ RSpec.describe Geo::WikiSyncService do
include
::
EE
::
GeoHelpers
include
ExclusiveLeaseHelpers
set
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
set
(
:secondary
)
{
create
(
:geo_node
)
}
set
(
:project
)
{
create
(
:project_empty_repo
)
}
let_it_be
(
:primary
)
{
create
(
:geo_node
,
:primary
)
}
let_it_be
(
:secondary
)
{
create
(
:geo_node
)
}
let_it_be
(
:project
)
{
create
(
:project_empty_repo
)
}
let
(
:repository
)
{
project
.
wiki
.
repository
}
let
(
:lease_key
)
{
"geo_sync_service:wiki:
#{
project
.
id
}
"
}
...
...
ee/spec/services/jira_connect/sync_service_spec.rb
View file @
cbb9492a
...
...
@@ -4,7 +4,7 @@ require 'spec_helper'
describe
JiraConnect
::
SyncService
do
describe
'#execute'
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:branches
)
{
[
project
.
repository
.
find_branch
(
'master'
)]
}
let
(
:commits
)
{
project
.
commits_by
(
oids:
%w[b83d6e3 5a62481]
)
}
let
(
:merge_requests
)
{
[
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)]
}
...
...
ee/spec/services/licenses/destroy_service_spec.rb
View file @
cbb9492a
...
...
@@ -4,7 +4,7 @@ require 'spec_helper'
describe
Licenses
::
DestroyService
do
let
(
:license
)
{
create
(
:license
)
}
set
(
:user
)
{
create
(
:admin
)
}
let_it_be
(
:user
)
{
create
(
:admin
)
}
def
destroy_with
(
user
)
described_class
.
new
(
license
,
user
).
execute
...
...
ee/spec/services/merge_trains/create_pipeline_service_spec.rb
View file @
cbb9492a
...
...
@@ -4,7 +4,7 @@ require 'spec_helper'
describe
MergeTrains
::
CreatePipelineService
do
let
(
:project
)
{
create
(
:project
,
:repository
,
:auto_devops
)
}
set
(
:maintainer
)
{
create
(
:user
)
}
let_it_be
(
:maintainer
)
{
create
(
:user
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
maintainer
)
}
let
(
:previous_ref
)
{
'refs/heads/master'
}
...
...
ee/spec/services/merge_trains/refresh_merge_request_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,8 +3,8 @@
require
'spec_helper'
describe
MergeTrains
::
RefreshMergeRequestService
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:maintainer
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:maintainer
)
{
create
(
:user
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
maintainer
,
require_recreate:
require_recreate
)
}
let
(
:require_recreate
)
{
false
}
...
...
ee/spec/services/merge_trains/refresh_merge_requests_service_spec.rb
View file @
cbb9492a
...
...
@@ -6,8 +6,8 @@ describe MergeTrains::RefreshMergeRequestsService do
include
ExclusiveLeaseHelpers
let
(
:project
)
{
create
(
:project
)
}
set
(
:maintainer_1
)
{
create
(
:user
)
}
set
(
:maintainer_2
)
{
create
(
:user
)
}
let_it_be
(
:maintainer_1
)
{
create
(
:user
)
}
let_it_be
(
:maintainer_2
)
{
create
(
:user
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
maintainer_1
)
}
before
do
...
...
ee/spec/services/metrics/dashboard/cluster_dashboard_service_spec.rb
View file @
cbb9492a
...
...
@@ -5,10 +5,10 @@ require 'spec_helper'
describe
Metrics
::
Dashboard
::
ClusterDashboardService
,
:use_clean_rails_memory_store_caching
do
include
MetricsDashboardHelpers
set
(
:user
)
{
create
(
:user
)
}
set
(
:cluster_project
)
{
create
(
:cluster_project
)
}
set
(
:cluster
)
{
cluster_project
.
cluster
}
set
(
:project
)
{
cluster_project
.
project
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:cluster_project
)
{
create
(
:cluster_project
)
}
let_it_be
(
:cluster
)
{
cluster_project
.
cluster
}
let_it_be
(
:project
)
{
cluster_project
.
project
}
before
do
project
.
add_maintainer
(
user
)
...
...
ee/spec/services/process_github_pull_request_event_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,8 +3,8 @@
require
'spec_helper'
describe
ProcessGithubPullRequestEventService
do
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:action
)
{
'opened'
}
let
(
:params
)
do
{
...
...
ee/spec/services/search/global_service_spec.rb
View file @
cbb9492a
...
...
@@ -21,7 +21,7 @@ describe Search::GlobalService do
context
'visibility'
,
:elastic
,
:sidekiq_inline
do
include_context
'ProjectPolicyTable context'
set
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let
(
:project
)
{
create
(
:project
,
project_level
,
namespace:
group
)
}
let
(
:user
)
{
create_user_from_membership
(
project
,
membership
)
}
...
...
ee/spec/services/search/group_service_spec.rb
View file @
cbb9492a
...
...
@@ -70,7 +70,7 @@ describe Search::GroupService, :elastic do
context
'visibility'
,
:sidekiq_inline
do
include_context
'ProjectPolicyTable context'
set
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let!
(
:project
)
{
create
(
:project
,
project_level
,
namespace:
group
)
}
let!
(
:project2
)
{
create
(
:project
,
project_level
)
}
let
(
:user
)
{
create_user_from_membership
(
project
,
membership
)
}
...
...
ee/spec/services/search/project_service_spec.rb
View file @
cbb9492a
...
...
@@ -20,7 +20,7 @@ describe Search::ProjectService do
context
'visibility'
,
:elastic
,
:sidekiq_inline
do
include_context
'ProjectPolicyTable context'
set
(
:group
)
{
create
(
:group
)
}
let_it_be
(
:group
)
{
create
(
:group
)
}
let!
(
:project
)
{
create
(
:project
,
project_level
,
namespace:
group
)
}
let!
(
:project2
)
{
create
(
:project
,
project_level
)
}
let
(
:user
)
{
create_user_from_membership
(
project
,
membership
)
}
...
...
ee/spec/services/security/report_fetch_service_spec.rb
View file @
cbb9492a
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
describe
Security
::
ReportFetchService
do
set
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let
(
:service
)
{
described_class
.
new
(
project
,
artifact
)
}
let
(
:artifact
)
{
::
Ci
::
JobArtifact
.
dependency_list_reports
}
...
...
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