Commit Graph

4 Commits

Author SHA1 Message Date
614abeb196 test: add comprehensive unit and integration tests
Backend Tests Added:
- Unit tests for helpers.js (tokens, validation, pagination)
- Unit tests for middleware (auth, errorHandler, validate)
- Integration tests for auth endpoints
- Integration tests for game endpoints
- Integration tests for admin endpoints
- Integration tests for employee endpoints
- Integration tests for draw endpoints
- Integration tests for newsletter/contact endpoints

Also added:
- cross-env for Windows compatibility
- Test scripts update

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 11:23:43 +01:00
ddc4c09323 fix: update test to use correct route (/) instead of /health 2025-11-18 16:59:43 +01:00
f9dd22909c fix: convert test to ES6 modules and export app
- Convert test/app.test.js from CommonJS to ES6 import/export
- Export app from index.js for testing
- Only start server if NODE_ENV !== 'test'
- Fixes 'require is not defined' error in tests
2025-11-18 16:53:46 +01:00
4312633bdb Mise à jour de index.js 2025-11-03 19:21:24 +01:00