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
1cfc54a2
Commit
1cfc54a2
authored
Aug 09, 2019
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Introduce new :sidekiq_inline{,_tech_debt} RSpec tags
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
64a2badf
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
1 deletion
+18
-1
spec/support/sidekiq.rb
spec/support/sidekiq.rb
+18
-1
No files found.
spec/support/sidekiq.rb
View file @
1cfc54a2
...
@@ -27,7 +27,9 @@ Sidekiq::Testing.server_middleware do |chain|
...
@@ -27,7 +27,9 @@ Sidekiq::Testing.server_middleware do |chain|
end
end
RSpec
.
configure
do
|
config
|
RSpec
.
configure
do
|
config
|
config
.
after
(
:each
,
:sidekiq
)
do
config
.
around
(
:each
,
:sidekiq
)
do
|
example
|
Sidekiq
::
Worker
.
clear_all
example
.
run
Sidekiq
::
Worker
.
clear_all
Sidekiq
::
Worker
.
clear_all
end
end
...
@@ -36,4 +38,19 @@ RSpec.configure do |config|
...
@@ -36,4 +38,19 @@ RSpec.configure do |config|
connection
.
redis
.
flushdb
connection
.
redis
.
flushdb
end
end
end
end
# As we'll review the examples with this tag, we should either:
# - fix the example to not require Sidekiq inline mode (and remove this tag)
# - explicitly keep the inline mode and change the tag for `:sidekiq_inline` instead
config
.
around
(
:example
,
:sidekiq_might_not_need_inline
)
do
|
example
|
Sidekiq
::
Worker
.
clear_all
Sidekiq
::
Testing
.
inline!
{
example
.
run
}
Sidekiq
::
Worker
.
clear_all
end
config
.
around
(
:example
,
:sidekiq_inline
)
do
|
example
|
Sidekiq
::
Worker
.
clear_all
Sidekiq
::
Testing
.
inline!
{
example
.
run
}
Sidekiq
::
Worker
.
clear_all
end
end
end
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