Skip to content
Snippets Groups Projects

Change Sidekiq testing mode to `fake` instead of `inline`

Merged Rémy Coutable requested to merge ee-22992-default-sidekiq-to-fake-mode-in-test-env into master

What does this MR do?

This changes the Sidekiq mode from inline to fake in the test environment.

This should hopefully make RSpec jobs run faster.

Documentation has been updated:

Sidekiq jobs are typically not run in specs, but this behaviour can be altered in each spec through the use of perform_enqueued_jobs blocks. Any spec that causes Sidekiq jobs to be pushed to Redis should use the :sidekiq_inline trait, to ensure that they are removed once the spec completes.

The :sidekiq_might_not_need_inline trait was added when Sidekiq inline mode was changed to fake mode to all the examples that needed Sidekiq to actually process jobs. Examples with this trait should be either fixed to not rely on Sidekiq processing jobs, or their :sidekiq_might_not_need_inline trait should be updated to :sidekiq_inline if the processing of background jobs is needed/expected.

Does this MR meet the acceptance criteria?

Conformity

Performance and testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team

Closes https://gitlab.com/gitlab-org/gitlab-ee/issues/16098.

Edited by Rémy Coutable

Merge request reports

Merge request pipeline #90451995 passed with warnings

Merge request pipeline passed with warnings for 6309f06b

Test coverage 82.47% (-0.02%) from 2 jobs
Approved by

Merged by Jan ProvaznikJan Provaznik 5 years ago (Oct 23, 2019 7:18am UTC)

Loading

Pipeline #90795240 failed

Pipeline failed for 58a1f0f9 on master

Test coverage 67.75% (-0.02%) from 2 jobs
4 environments impacted.

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading