Skip to content

Commit 12136fb

Browse files
authored
test(template): add type compiler validation tests (JhaSourav07#3311)
## Description Fixes JhaSourav07#2872 Added `app/template.type-compiler.test.tsx` to provide isolated type compiler validation and schema constraint stability coverage for `app/template.tsx`. Implemented 5 tests covering: * Type enforcement for the `children` prop using `expectTypeOf` * Validation that invalid prop parameters are blocked during static type checking * Optional/valid ReactNode compatibility checks * Runtime rendering validation for valid children * Stability verification for `null` children without runtime crashes Verified the new test file passes with: `npx vitest run app/template.type-compiler.test.tsx` ## Pillar * [ ] 🎨 Pillar 1 — New Theme Design * [ ] 📐 Pillar 2 — Geometric SVG Improvement * [ ] 🕐 Pillar 3 — Timezone Logic Optimization * [x] 🛠️ Other (Bug fix, refactoring, docs) ## Visual Preview N/A (test-only change) ## Checklist before requesting a review: * [x] I have read the `CONTRIBUTING.md` file. * [x] I have tested these changes locally (`localhost:3000/api/streak?user=YOUR_USERNAME`). * [ ] I have run `npm run format` and `npm run lint` locally and resolved all errors (CI will fail otherwise). * [x] My commits follow the Conventional Commits format (e.g., `feat(themes): ...`, `fix(calculate): ...`). * [ ] I have updated `README.md` if I added a new theme or URL parameter. * [x] I have started the repo. * [x] I have made sure that i have only one commit to merge in this PR. * [ ] The SVG output matches the CommitPulse "premium quality" aesthetic standard (no raw elements, smooth animations, correct fonts). * [ ] (Recommended) I joined the CommitPulse Discord community for contributor discussions, mentorship, and faster PR support.
2 parents ce06e94 + 2f02d3d commit 12136fb

0 file changed

File tree

    0 commit comments

    Comments
     (0)