fix: add first_payment to EmailType test expected values #382
No reviewers
Labels
No labels
domain:backend
domain:devops
domain:frontend
status:approved
status:in-progress
status:needs-fix
status:qa
type:bug
type:devops
type:feature
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
forgejo_admin/basketball-api!382
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix-email-type-test"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
first_paymentEmailType enum but didn't updatetest_all_expected_valuesupdate-kustomize-tagskipped, no deploys"first_payment"to the expected setChanges
tests/test_templated_email.py: add"first_payment"toexpectedset intest_all_expected_valuesTest Plan
update-kustomize-tagReview Checklist
Related Notes
westside-basketball— project affected by blocked deploysPR #382 Review
DOMAIN REVIEW
Stack: Python / FastAPI / SQLAlchemy (basketball-api)
This is a one-line test fix. PR #370 added
first_paymentto theEmailTypeenum and introducedtest_templated_email.pywith atest_all_expected_valuestest that asserts all enum values are present in an expected set. Thefirst_paymentvalue was added to the enum but omitted from that expected set, causing CI to fail on every subsequent merge.Correctness: The fix adds
"first_payment"to the expected set at the correct location (aftersponsor_outreach, before the closing brace). The test patternexpected == {e.value for e in EmailType}will catch any future drift in either direction -- this is a good guard test.Completeness: Searched all test files referencing
EmailType. No other tests enumerate the full set of values, so this is the only place that needed updating. Tests intest_tryouts.py,test_groupme.py,test_admin_email.py, andtest_admin_registration_notification.pyreference individual enum values, not the complete set.Scope: Exactly one file changed, one line added. No unnecessary changes.
BLOCKERS
None.
NITS
fix-email-type-testrather than381-fix-email-type-test. Convention is{issue-number}-{kebab-case-purpose}. Minor for a hotfix, but worth noting.SOP COMPLIANCE
fix-email-type-testmissing381-prefix)PROCESS OBSERVATIONS
This is a CI-unblocking hotfix. The root cause is a process gap: PR #370 added an enum value but the reviewer (human or automated) did not catch the missing test update. This is exactly the class of bug that enum completeness tests are designed to catch -- the test was correct, it just wasn't updated alongside the enum change. Future PRs that add enum values should treat the completeness test as a mandatory co-change. No DORA metric impact beyond the deploy blockage this fix resolves.
VERDICT: APPROVED