-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Removed extra pciu migration flippers #21108
base: master
Are you sure you want to change the base?
Conversation
Generated by 🚫 Danger |
@@ -119,8 +119,7 @@ def form_526_required_identifiers | |||
end | |||
|
|||
def vet360_contact_information | |||
contact_info_v2_enabled = Flipper.enabled?(:va_v3_contact_information_service, user) | |||
person = contact_info_v2_enabled ? user.vaprofile_contact_info : user.vet360_contact_info | |||
person = user.vet360_contact_info | |||
return {} if person.blank? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No longer need user.vaprofile_contact_info
|
||
before do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed ContactInformationV1 from cache aside spec.
else | ||
'va_profile/contact_information' | ||
end | ||
allow(Flipper).to receive(:enabled?).with(:remove_pciu, instance_of(User)).and_return(true) | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cleaned up code.
@@ -337,7 +339,7 @@ | |||
|
|||
it "can't have non-hash formData" do | |||
put v0_in_progress_form_url(new_form.form_id), | |||
params: { form_data: 'Hello!' }.to_json, | |||
params: { form_data: '' }.to_json, | |||
headers: { 'CONTENT_TYPE' => 'application/json' } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was intentional. Form data should be ''
allow(Flipper).to receive(:enabled?).with(:remove_pciu, instance_of(User)).and_return(true) | ||
allow(VAProfile::Configuration::SETTINGS.contact_information).to receive(:cache_enabled).and_return(true) | ||
user.vaprofile_contact_info | ||
user.vet360_contact_info | ||
sign_in_as(user) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
user.vaprofile_contact_info no longer needed.
VAProfileRedis::V2::ContactInformation.for_user(self) | ||
else | ||
elsif !Flipper.enabled?(:remove_pciu, self) && vet360_id.present? | ||
VAProfileRedis::ContactInformation.for_user(self) | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VAProfileRedis::V2::ContactInformation.for_user(self) requires icn.
VAProfileRedis::ContactInformation.for_user(self) requires vet360_id
@@ -46,7 +46,7 @@ def encrypted_user | |||
uuid: current_user.uuid, | |||
icn: current_user.icn, | |||
first_name: current_user.first_name, | |||
va_profile_email: current_user.va_profile_email || current_user.va_profile_v2_email | |||
va_profile_email: current_user.va_profile_email | |||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
current_user.va_profile_v2_email no longer needed.
@@ -38,7 +38,7 @@ def service_auth_map | |||
prescriptions: access?(mhv_prescriptions: :access?), | |||
scheduleAppointments: access?(schedule_appointment: :access?), | |||
secureMessaging: access?(mhv_messaging: :mobile_access?), | |||
userProfileUpdate: access?(vet360: :access?) | |||
userProfileUpdate: access?(va_profile: :access_to_v2?) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated for icn requirements.
Note: Delete the description statements, complete each step. None are optional, but can be justified as to why they cannot be completed as written. Provide known gaps to testing that may raise the risk of merging to production.
Summary
:remove_pciu
flipper is replacingva_v3_contact_information_service
andremove_pciu_2
. This will allow an easy flow to enable VAProfile CIV2 and AddressValidationV3 in production.The
remove_pciu
flipper was added to the vet360_contact_info method in the User model. user.vaprofile_contact_info and user.va_profile_v2_email is no longer necessary.Related issue(s)
Testing done
Screenshots
Note: Optional
What areas of the site does it impact?
(Describe what parts of the site are impacted andifcode touched other areas)
Acceptance criteria
Requested Feedback
(OPTIONAL)What should the reviewers know in addition to the above. Is there anything specific you wish the reviewer to assist with. Do you have any concerns with this PR, why?