Skip to content

Refactor email otp enrollment callout spec to not be flakey

What does this MR do and why?

Refactor email otp enrollment callout spec to not be flakey

Previously the spec would click the two dismissal buttons and check the callout stayed dismissed. This was flakey.

Waiting for the class .page-initialised to appear in the body is the fix, as per !206136 (comment 2774300025)

Closes [Test] spec/features/callouts/email_otp_enrollm... (#570553 - closed) • Nick Malcolm

Screenshots or screen recordings

N/A

How to set up and validate locally

  1. Check out the branch
  2. Run the spec using any / all of the flakey seeds:
    bundle exec rspec spec/features/callouts/email_otp_enrollment_callout_spec.rb --seed 52560 --fail-fast &&
      bundle exec rspec spec/features/callouts/email_otp_enrollment_callout_spec.rb --seed 24850 --fail-fast &&
      bundle exec rspec spec/features/callouts/email_otp_enrollment_callout_spec.rb --seed 3731 --fail-fast &&
      bundle exec rspec spec/features/callouts/email_otp_enrollment_callout_spec.rb --seed 52009 --fail-fast

MR acceptance checklist

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

Related to #570553 (closed)

Edited by Nick Malcolm

Merge request reports

Loading