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

Fix: Re-enrollment #1804

Merged
merged 2 commits into from Dec 1, 2023
Merged

Fix: Re-enrollment #1804

merged 2 commits into from Dec 1, 2023

Conversation

thekaveman
Copy link
Member

Fixes #1803

do not rely on specific text of the error message
instead check for presence of customer ID and group ID
@thekaveman thekaveman requested a review from a team as a code owner December 1, 2023 20:16
@github-actions github-actions bot added deployment-dev [auto] Changes that will trigger a deploy if merged to dev tests Related to automated testing (unit, UI, integration, etc.) back-end Django views, sessions, middleware, models, migrations etc. and removed deployment-dev [auto] Changes that will trigger a deploy if merged to dev labels Dec 1, 2023
Copy link

github-actions bot commented Dec 1, 2023

Coverage report

The coverage rate went from 90.87% to 90.87% ➡️
The branch rate is 85%.

100% of new lines are covered.

Diff Coverage details (click to unfold)

benefits/enrollment/api.py

100% of new lines are covered (94.54% of the complete file).

@thekaveman thekaveman self-assigned this Dec 1, 2023
@@ -74,18 +74,12 @@ def __init__(self, response, requested_id, payload=None):
else:
try:
# Group API uses an error response (500) to indicate that the customer already exists in the group (!!!)
# The error message should contain the customer ID we sent via payload and start with "Duplicate"
# The error message should contain the customer ID and group ID we sent via payload
Copy link
Member

Choose a reason for hiding this comment

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

👍

Copy link
Member

@angela-tran angela-tran left a comment

Choose a reason for hiding this comment

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

This looks good to me

@thekaveman thekaveman merged commit 9738532 into dev Dec 1, 2023
17 checks passed
@thekaveman thekaveman deleted the fix/reenrollment branch December 1, 2023 21:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
back-end Django views, sessions, middleware, models, migrations etc. tests Related to automated testing (unit, UI, integration, etc.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Adjust handling of enrollment when customer already exists in group
2 participants