-
Notifications
You must be signed in to change notification settings - Fork 2
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
MLPAB-2692: Allow changing details after a failed vouch #1694
MLPAB-2692: Allow changing details after a failed vouch #1694
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1694 +/- ##
=======================================
Coverage 95.00% 95.01%
=======================================
Files 285 285
Lines 16242 16253 +11
=======================================
+ Hits 15431 15442 +11
Misses 641 641
Partials 170 170
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@@ -44,7 +44,7 @@ describe('what you can do now', () => { | |||
cy.url().should('contain', '/task-list') | |||
cy.checkA11yApp() | |||
|
|||
cy.contains('li', "Confirm your identity").should('contain', 'Completed').click(); | |||
cy.contains('li', "Confirm your identity").should('contain', 'In progress').click(); |
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.
Unless there were changes after the original ticket I think this assertion was incorrect.
<p class="govuk-inset-text">{{ tr .App "someOfTheseDetailsCanNoLongerBeChanged" }}</p> | ||
{{ end }} | ||
|
||
{{ if $vouchInProgress }} |
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.
I've added https://opgtransform.atlassian.net/browse/MLPAB-2778 to get some updated content.
// CanChange returns true if the donor can make changes to their LPA. | ||
func (p *Provided) CanChange() bool { | ||
return p.SignedAt.IsZero() | ||
// CanChangePersonalDetails returns true if the donor can make changes to their FirstNames, LastName or DateOfBirth. |
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.
I'd prefer us to keep CanChange
too then, and have CanChangePersonalDetails
use that instead of !p.SignedAt.IsZero
. I just don't trust that the condition won't change in future, and it is a bit nicer to read
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.
Fair point - I was on the fence as it was only checking one prop but, like you said, this could change.
Purpose
Fixes MLPAB-2692