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
2b8bc704
Commit
2b8bc704
authored
Feb 21, 2020
by
Vitali Tatarintev
Committed by
Heinrich Lee Yu
Feb 25, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replace set with let_it_in in spec/workers
Removes usage of `set` in specs
parent
427bce1a
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
13 additions
and
13 deletions
+13
-13
spec/workers/detect_repository_languages_worker_spec.rb
spec/workers/detect_repository_languages_worker_spec.rb
+1
-1
spec/workers/expire_build_instance_artifacts_worker_spec.rb
spec/workers/expire_build_instance_artifacts_worker_spec.rb
+1
-1
spec/workers/expire_job_cache_worker_spec.rb
spec/workers/expire_job_cache_worker_spec.rb
+1
-1
spec/workers/mail_scheduler/notification_service_worker_spec.rb
...orkers/mail_scheduler/notification_service_worker_spec.rb
+1
-1
spec/workers/pipeline_schedule_worker_spec.rb
spec/workers/pipeline_schedule_worker_spec.rb
+2
-2
spec/workers/remote_mirror_notification_worker_spec.rb
spec/workers/remote_mirror_notification_worker_spec.rb
+2
-2
spec/workers/run_pipeline_schedule_worker_spec.rb
spec/workers/run_pipeline_schedule_worker_spec.rb
+3
-3
spec/workers/update_external_pull_requests_worker_spec.rb
spec/workers/update_external_pull_requests_worker_spec.rb
+2
-2
No files found.
spec/workers/detect_repository_languages_worker_spec.rb
View file @
2b8bc704
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
describe
DetectRepositoryLanguagesWorker
do
set
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
subject
{
described_class
.
new
}
...
...
spec/workers/expire_build_instance_artifacts_worker_spec.rb
View file @
2b8bc704
...
...
@@ -31,7 +31,7 @@ describe ExpireBuildInstanceArtifactsWorker do
end
context
'with not yet expired artifacts'
do
set
(
:build
)
do
let_it_be
(
:build
)
do
create
(
:ci_build
,
:artifacts
,
artifacts_expire_at:
Time
.
now
+
7
.
days
)
end
...
...
spec/workers/expire_job_cache_worker_spec.rb
View file @
2b8bc704
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
describe
ExpireJobCacheWorker
do
set
(
:pipeline
)
{
create
(
:ci_empty_pipeline
)
}
let_it_be
(
:pipeline
)
{
create
(
:ci_empty_pipeline
)
}
let
(
:project
)
{
pipeline
.
project
}
describe
'#perform'
do
...
...
spec/workers/mail_scheduler/notification_service_worker_spec.rb
View file @
2b8bc704
...
...
@@ -6,7 +6,7 @@ describe MailScheduler::NotificationServiceWorker do
let
(
:worker
)
{
described_class
.
new
}
let
(
:method
)
{
'new_key'
}
set
(
:key
)
{
create
(
:personal_key
)
}
let_it_be
(
:key
)
{
create
(
:personal_key
)
}
def
serialize
(
*
args
)
ActiveJob
::
Arguments
.
serialize
(
args
)
...
...
spec/workers/pipeline_schedule_worker_spec.rb
View file @
2b8bc704
...
...
@@ -7,8 +7,8 @@ describe PipelineScheduleWorker do
subject
{
described_class
.
new
.
perform
}
set
(
:project
)
{
create
(
:project
,
:repository
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let!
(
:pipeline_schedule
)
do
create
(
:ci_pipeline_schedule
,
:nightly
,
project:
project
,
owner:
user
)
...
...
spec/workers/remote_mirror_notification_worker_spec.rb
View file @
2b8bc704
...
...
@@ -3,8 +3,8 @@
require
'spec_helper'
describe
RemoteMirrorNotificationWorker
,
:mailer
do
set
(
:project
)
{
create
(
:project
,
:repository
,
:remote_mirror
)
}
set
(
:mirror
)
{
project
.
remote_mirrors
.
first
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
,
:remote_mirror
)
}
let_it_be
(
:mirror
)
{
project
.
remote_mirrors
.
first
}
describe
'#execute'
do
it
'calls NotificationService#remote_mirror_update_failed when the mirror exists'
do
...
...
spec/workers/run_pipeline_schedule_worker_spec.rb
View file @
2b8bc704
...
...
@@ -4,9 +4,9 @@ require 'spec_helper'
describe
RunPipelineScheduleWorker
do
describe
'#perform'
do
set
(
:project
)
{
create
(
:project
)
}
set
(
:user
)
{
create
(
:user
)
}
set
(
:pipeline_schedule
)
{
create
(
:ci_pipeline_schedule
,
:nightly
,
project:
project
)
}
let_it_be
(
:project
)
{
create
(
:project
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:pipeline_schedule
)
{
create
(
:ci_pipeline_schedule
,
:nightly
,
project:
project
)
}
let
(
:worker
)
{
described_class
.
new
}
context
'when a project not found'
do
...
...
spec/workers/update_external_pull_requests_worker_spec.rb
View file @
2b8bc704
...
...
@@ -4,8 +4,8 @@ require 'spec_helper'
describe
UpdateExternalPullRequestsWorker
do
describe
'#perform'
do
set
(
:project
)
{
create
(
:project
,
import_source:
'tanuki/repository'
)
}
set
(
:user
)
{
create
(
:user
)
}
let_it_be
(
:project
)
{
create
(
:project
,
import_source:
'tanuki/repository'
)
}
let_it_be
(
:user
)
{
create
(
:user
)
}
let
(
:worker
)
{
described_class
.
new
}
before
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