-
Notifications
You must be signed in to change notification settings - Fork 66
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
add models and unit test #16320
add models and unit test #16320
Conversation
Hi @cloudmagic80, you'll need to update the CODEOWNERS file since you're adding new files. We have an automated CI check for that but i just learned (thanks to your PR! 😄) that it passes (falsely) if you add more than one new file. I have a pr to fix this, but you don't need to wait on that–the CI check would just tell you to add those files to CODEOWNERS. |
Error: A file (or its parent directories) does not have a CODEOWNERS entry. Please update the .github/CODEOWNERS file and add the entry for the Offending file: app/models/pega_table.rb |
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.
lgtm
@rmtolmach Are the @department-of-veterans-affairs/va-api-engineers @department-of-veterans-affairs/backend-review-group the code reviewers? |
@cloudmagic80 You'll want to add @department-of-veterans-affairs/backend-review-group AND your team as the code reviewers for all three of those files. |
.github/CODEOWNERS
Outdated
@@ -1441,6 +1443,7 @@ spec/models/message_spec.rb @department-of-veterans-affairs/vfs-mhv-secure-messa | |||
spec/models/mhv_opt_in_flag_spec.rb @department-of-veterans-affairs/vfs-mhv-secure-messaging @department-of-veterans-affairs/va-api-engineers @department-of-veterans-affairs/backend-review-group | |||
spec/models/mpi_data_spec.rb @department-of-veterans-affairs/octo-identity | |||
spec/models/onsite_notification_spec.rb @department-of-veterans-affairs/vfs-authenticated-experience-backend @department-of-veterans-affairs/va-api-engineers @department-of-veterans-affairs/backend-review-group | |||
spec/models/pega_table_spec.rb @department-of-veterans-affairs/va-api-engineers @department-of-veterans-affairs/backend-review-group |
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.
You also need to add your github team as reviewers. Which team will be responsible for these files? If you don't have a team, pleas create one. https://github.com/orgs/department-of-veterans-affairs/teams
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.
@rmtolmach I see @department-of-veterans-affairs/champva-engineering in our github teams but in CODEOWNERS, its not recognized
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.
@rmtolmach Can you help out?
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.
Yes! I've added champva-engineering to the vets-api repo as collaborators with write access so the warnings are gone 👍
@@ -0,0 +1,24 @@ | |||
# frozen_string_literal: true | |||
|
|||
class PegaTable < ApplicationRecord |
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.
Can we change the file name and model to just be "Pega" to match the format of other models? @cloudmagic80
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.
Or maybe PegaData for a bit more clarity since we are storing the response in there right?
I thought we discussed changes for this yesterday that made more sense to do @cloudmagic80 |
This PR is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
This PR has been closed because it has had no activity for 37 days |
Summary
This repository contains the implementation of the PegaTable model in Ruby on Rails. The PegaTable model is designed to represent data related to a Pega table in a Rails application. It includes validations to ensure the presence of essential fields such as UUID, veteran first name, veteran last name, and response. Additionally, it validates the format of the response field to ensure it contains a valid HTTP status code (200, 403, 500) and is in JSON format.
Key Features:
Validates presence of essential fields.
Validates format of the response field to ensure it contains a valid HTTP status code and is in JSON format.
Utilizes exceptions handling to gracefully handle JSON parsing errors.
Related issue(s)
#16311
Testing done
What areas of the site does it impact?
Non so far. It is only in staging. not in production
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?