Skip to content

Refactor approval_wrapped_rule specs

What does this MR do and why?

This MR refactors the specs for ApprovalWrappedRule to follow the Testing best practices.

More specifically, it touches on the following points:

  • Avoid referencing subject in examples. Use a named subject subject(:name), or a let variable instead, so the variable has a contextual name.
  • If the subject is never referenced inside examples, then it’s acceptable to define the subject without a name.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #410456 (closed)

Edited by Martin Čavoj

Merge request reports

Loading