Skip to content

Fixed flaky billable member spec

Suraj Tripathi requested to merge 458331_fix_flaky_billable_spec into master

What does this MR do and why?

The order of execution of the different context causes the flakiness of the spec. The membership variable is defined using a let_it_be here and then updated to add a custom-role here, when with custom role runs it updates the membership record to have a custom_role, which results in this assertion failing in the without custom role spec.

The change modifies declaration of membership from let_it_be to let_it_be_with_reload to ensure membership object is reset between contexts

ref: #458331 (closed)

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Edited by Suraj Tripathi

Merge request reports