care icon indicating copy to clipboard operation
care copied to clipboard

feat: Added validation for max dosage and corresponding test cases #2383

Open himanshu-sharmav opened this issue 4 months ago • 3 comments

Fixes: #2383

  • Added validation to ensure max dosage is greater than or equal to base dosage in PrescriptionSerializer.
  • Added test cases to validate the new dosage constraints.
  • Updated test_prescriptions_api.py to include tests for valid, equal, and invalid dosage scenarios.

Resolves issue with incorrect dosage validation.

Merge Checklist

  • [ X] Tests added/fixed
  • [ X] Update docs in /docs
  • [ X] Linting Complete
  • [ X] Any other necessary step

Only PR's with test cases included and passing lint and test pipelines will be reviewed

@ohcnetwork/care-backend-maintainers @ohcnetwork/care-backend-admins

himanshu-sharmav avatar Oct 12 '24 19:10 himanshu-sharmav