Skip to content
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

Tforkner/4030 subform cancel #4132

Merged
merged 14 commits into from
Jun 21, 2022
Merged

Tforkner/4030 subform cancel #4132

merged 14 commits into from
Jun 21, 2022

Conversation

thetif
Copy link
Contributor

@thetif thetif commented Jun 10, 2022

Resolves #4030

Description

There was an issue where updates were being saved in metrics even when the user clicked cancel. I have updated metrics and the other subforms, to not save anything that was updated if the user clicks cancel.

Automated test cases written

added a cypress test to add info to a metric and then click cancel

Steps to manually verify this change

  1. Create an outcome with a metric
  2. edit the metric and click cancel
  3. verify the changes you made were not saved

Please test by trying difference cases of canceling for all subforms:
Key State Personnel
Outcomes and Metrics
Milestones
State Staff
State Expenses
Private Contractor Costs

This pull request is ready to review when

  • Automated tests are updated (and all tests are passing)
  • The experience passes a basic manual accessibility audit (keyboard nav, screenreader, text scaling) OR an exemption is documented

This pull request can be merged when

  • Code has been reviewed by someone other than the original author
  • QA has verified the accessibility and functionality related to the change
  • Design has approved the experience
  • Product has approved the experience

@thetif thetif requested a review from tbolt June 10, 2022 18:24
@codecov-commenter
Copy link

codecov-commenter commented Jun 10, 2022

Codecov Report

Merging #4132 (e2f7265) into main (03d6d34) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #4132   +/-   ##
=======================================
  Coverage   87.65%   87.65%           
=======================================
  Files         215      215           
  Lines        4932     4932           
  Branches     1259     1259           
=======================================
  Hits         4323     4323           
  Misses        556      556           
  Partials       53       53           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 03d6d34...e2f7265. Read the comment docs.

Copy link
Contributor

@tbolt tbolt left a comment

Choose a reason for hiding this comment

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

Code looks good and it resolved the issue in the instances I tested

@cms-eapd-bot
Copy link

cms-eapd-bot commented Jun 10, 2022

This deploy was cleaned up.

@mirano-darren
Copy link
Contributor

Well done! Tested locally since preview builds were running into an issue when I checked it out. (APDs weren't loading)

Given When Then Result
a subform editing the subform and clicking cancel the changes aren't saved PASS ✔️

Checked on all these subforms:
Key State Personnel
Outcomes and Metrics
Milestones
State Staff
State Expenses
Private Contractor Costs

Copy link
Contributor

@jeromeleecms jeromeleecms left a comment

Choose a reason for hiding this comment

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

Tested against all the subforms as listed. Works as advertised!

@tbolt tbolt added the bug needs triage, then squashing label Jun 21, 2022
@tbolt tbolt merged commit ee71d41 into main Jun 21, 2022
@tbolt tbolt deleted the tforkner/4030-metrics-saved-error branch June 21, 2022 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug needs triage, then squashing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] Metrics are saved if "Cancel" is clicked
8 participants