Increase Test Coverage to 100% for Patient Components
📝 Description
We need to improve unit test coverage to 100% for the following components:
- PatientCard.tsx
- PatientStatusTracker.tsx
- QueueDisplay.tsx
Currently, these components have partial coverage, and some branches, edge cases, and conditional paths are not fully tested.
🎯 Objective
Achieve 100% test coverage (Statements, Branches, Functions, and Lines) for the above components.
✅ Tasks
-
Analyze current coverage report ( npm run test:coverage) -
Identify uncovered lines, branches, and edge cases -
Write additional test cases for: - Conditional rendering
- Edge cases (empty data, null/undefined props)
- User interactions (clicks, status changes, etc.)
- API/mock data handling (if applicable)
-
Ensure all tests pass successfully -
Verify coverage reaches 100% for each file
🧪 Acceptance Criteria
-
Coverage for:
- PatientCard.tsx → 100%
- PatientStatusTracker.tsx → 100%
- QueueDisplay.tsx → 100%
-
No failing test cases
-
Code follows existing testing standards (Jest + React Testing Library)
Edited by Rajuldev Vandana