Commit Graph

15 Commits

Author SHA1 Message Date
e77be200c8 test: improve middleware test coverage and configure SonarQube exclusions
- Add --coverage flag to npm test script
- Add lcov coverage reporters for SonarQube integration
- Add tests for expired token handling
- Add tests for all errorHandler error types
- Add tests for validate middleware edge cases
- Add coverage exclusions for controllers/services in SonarQube

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

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 15:07:02 +01:00
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
0e1cd727c4 feat: add SonarQube integration for code quality analysis
- Add SonarQube configuration files
  - sonar-project.properties with Node.js/Express settings
  - .sonarignore to exclude test files, database, and build artifacts
  - Configure source paths (src, index.js, db.js)
  - Set up test coverage paths

- Add SonarQube npm script
  - npm run sonar command for manual analysis

- Integrate SonarQube into Jenkins pipeline
  - Add SonarQube Analysis stage with sonar-scanner-cli
  - Add Quality Gate verification stage
  - Block deployment if quality gate fails
  - 5-minute timeout for quality gate check

This enables continuous code quality monitoring and ensures
code meets quality standards before deployment.

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

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-21 01:24:59 +01:00
9330c68e5c fix: improve CI/CD quality checks and fix test/lint configuration
Backend fixes:
- Add eslint.config.js with proper ES6 module configuration
- Add jest.config.js to support ES modules
- Update package.json with @eslint/js dependency
- Configure npm test script with NODE_OPTIONS for ES modules
- Update Jenkinsfile to block deployments on failed lint/tests

This ensures:
1. ESLint works correctly with ES6 modules
2. Jest can run tests with ES6 imports
3. Deployments are blocked if quality checks fail

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

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-18 15:40:04 +01:00
25c7a0b304 dev 2025-11-17 23:47:54 +01:00
4312633bdb Mise à jour de index.js 2025-11-03 19:21:24 +01:00
4a732b5f59 Fix Jenkinsfile: force recreate + health check 2025-11-01 17:32:37 +01:00
15bd1f0610 Fix Jenkinsfile: force recreate + health check 2025-11-01 17:25:01 +01:00
720b307d7e Initial commit du frontend The Tip Top 2025-10-30 11:11:05 +00:00
c1793f6383 flatten backend folder 2025-10-28 00:31:47 +01:00
56b9854afa flatten backend folder 2025-10-26 01:53:35 +02:00
8404d365f8 sauvegarde avant pull 2025-10-25 23:21:31 +00:00
c59b58c812 push 2025-10-25 03:32:37 +02:00
fc67cf6415 push
All checks were successful
the-tip-top-backend/pipeline/head This commit looks good
2025-10-24 14:14:46 +02:00
root
fb3d2cfd3f Initial commit - backend depuis VPS 2025-10-22 20:40:47 +00:00