Skip to content

LG-11904 Add 50/50 state tests for opt in navigation#9798

Merged
JackRyan1989 merged 10 commits intomainfrom
jryan/lg-11904-test-opt-in-fifty-fifty-state
Dec 20, 2023
Merged

LG-11904 Add 50/50 state tests for opt in navigation#9798
JackRyan1989 merged 10 commits intomainfrom
jryan/lg-11904-test-opt-in-fifty-fifty-state

Conversation

@JackRyan1989
Copy link
Contributor

🎫 Ticket

🛠 Summary of changes

Added new specs to handle the following cases during page navigation around the opt-in IPP How To Verify controller. We wanted some tests in place to define and confirm the behavior of the system during the 50/50 state. To simulate ending up on an instance that has a different config value than the one available on the previous page, we refresh the page after toggling the configuration state and see what happens.

Conditions:

  1. Forward navigation to /how_to_verify

📜 Testing Plan

These are specs, so you can run them locally using rspec or view the output of the CI/CD here in Github.

@JackRyan1989 JackRyan1989 self-assigned this Dec 19, 2023
@JackRyan1989 JackRyan1989 requested review from a team and gina-yamada December 19, 2023 16:33
@JackRyan1989 JackRyan1989 marked this pull request as ready for review December 19, 2023 17:14
end

describe 'navigating to How To Verify from Agreement page in 50/50 state' do
context 'opt in false at start but true during navigation' do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in_person_proofing_opt_in_enabled can be enabled and a user can opt in or opt out. I think we should be very specific here. What do you think about something like 'in_person_proofing_opt_in_enabled is false at start but true during navigation' rather than 'opt in false'? If you like this, I'd suggest we make this change for each context block.

end
end

context 'Going back from Hybrid Handoff with opt in enabled midstream' do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see tests around going back from IPP.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since we aren't toggling IPP with this deploy, I wasn't sure that I wanted to capture it?

Copy link
Contributor

@gina-yamada gina-yamada Dec 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a new flow/path so I thought a good idea, maybe too much/not necessary?

Previously, if the user was on verify/document_capture#prepare and went back- they'd go back to document capture- but in this case- they should go back to how to verify.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, sorry I misunderstood. Yeah let me write some specs handling the back from document capture cases. Thanks!

Copy link
Contributor

@soniaconnolly soniaconnolly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a good idea! Recommend combining specs in each context like I said in one of the comments, and otherwise looks good.

it 'should not be bounced back from Hybrid Handoff to How to Verify' do
expect(page).to have_current_path(idv_hybrid_handoff_url)
allow(IdentityConfig.store).to receive(:in_person_proofing_opt_in_enabled) { true }
page.refresh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oooh i didn't know about refresh, very useful!

Copy link
Contributor

@svalexander svalexander left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this was a great idea, thanks for suggesting and implementing these specs!

@JackRyan1989 JackRyan1989 merged commit b157a24 into main Dec 20, 2023
@JackRyan1989 JackRyan1989 deleted the jryan/lg-11904-test-opt-in-fifty-fifty-state branch December 20, 2023 21:25
Copy link
Contributor

@n1zyy n1zyy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know this is already merged, but I wanted to echo Shannon's comments. This is great stuff. I think this helps build a lot of confidence in the upcoming release.

end

it 'skips when disabled and redirects to hybird handoff)' do
it 'skips when disabled and redirects to hybrid handoff' do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🐦 Nice catch. :)

@jmdembe jmdembe mentioned this pull request Dec 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants