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

Disable 15 minutes validation for New Case Contact Form #5288

Conversation

sarvaiyanidhi
Copy link
Contributor

What github issue is this PR for, if any?

Resolves #5287

What changed, and why?

Removed the duration validation from New Case Contact form so that form can be submitted even if minutes is set to 0 instead of earlier validation of minimum 15mins

How will this affect user permissions?

  • Volunteer permissions: Not Effected
  • Supervisor permissions: Not Effected
  • Admin permissions: Not Effected

How is this tested? (please write tests!) 💖💪

Modified the existing tests checking for 15mins duration validation.

Screenshots please :)

Duration validation is not triggered now.

CASA-Volunteer-Tracking-new-contact-form

Feelings gif (optional)

What gif best describes your feeling working on this issue? https://giphy.com/
How to embed:
![alt text](https://media.giphy.com/media/1nP7ThJFes5pgXKUNf/giphy.gif)

Feedback please? (optional)

We are very interested in your feedback! Please give us some :) https://forms.gle/1D5ACNgTs2u9gSdh9

@github-actions github-actions bot added ruby Pull requests that update Ruby code Tests! 🎉💖👏 labels Oct 18, 2023
Copy link
Collaborator

@schoork schoork left a comment

Choose a reason for hiding this comment

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

Thanks for the quick work!

@@ -319,7 +319,7 @@

context "with invalid parameters" do
let!(:other_casa_case) { create(:casa_case, casa_org: organization) }
let(:invalid_attributes) { {creator: volunteer, casa_case_id: [other_casa_case.id]} }
let(:invalid_attributes) { {creator: "volunteer", casa_case_id: [other_casa_case.id], occurred_at: Time.now + 1.week} }
Copy link
Collaborator

Choose a reason for hiding this comment

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

This volunteer references a volunteer created earlier in the testing class. Any reason why you turned it into a string?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not sure how it got updated to string I think it was some typo error from my end. Thanks for correcting it.

@schoork schoork merged commit d521c78 into rubyforgood:main Oct 22, 2023
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ruby Pull requests that update Ruby code Tests! 🎉💖👏
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Disable the 15 minute validation
2 participants