-
-
Notifications
You must be signed in to change notification settings - Fork 66
Open
Description
Problem
The project currently has 0% test coverage. I verified there are no .test. or .spec. files in the codebase. This means no automated way to catch regressions, verify refactors, or validate PR changes.
Proposed solution
Set up Vitest testing infrastructure with initial coverage for core modules.
Implementation:
- Configure Vitest + React Testing Library + happy-dom
- Write 50+ unit tests for:
- src/robotoff.ts (API client)
- src/off.ts (Open Food Facts API)
- src/utils.ts (utilities)
- Add GitHub Actions workflow for CI testing
- Create TESTING.md documentation
Why Vitest: Vite-native (already using Vite), faster than Jest, compatible API.
Additional context
Deliverables:
- vitest.config.ts configuration
- 50+ test files
- .github/workflows/test.yml CI workflow
- Testing documentation
Timeline: 3-4 days
Design & mockups
N/A - Infrastructure contribution
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
To Discuss & Validate