Commit graph

7 commits

Author SHA1 Message Date
Tiago Yamamoto
61d64d846a fix(jobs): enforce CreateJob validation and sanitize DB constraint errors
- Add validateCreateJobRequest() checking required fields (companyId,
  title ≥5 chars, description ≥20 chars) and enum values
  (employmentType, workMode, status) before hitting the DB
- Catch *pq.Error in handler: check_violation (23514) and
  foreign_key_violation (23503) now return 400; unique_violation (23505)
  returns 409; other DB errors return 500 without leaking raw pq messages
- Fix test fixtures: description and companyId now meet validation
  requirements

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-22 12:26:14 -06:00
Tiago Yamamoto
fb5aba4ed7 backend: suportar workMode em vagas e reforçar schema 2026-02-15 13:36:32 -03:00
Tiago Yamamoto
b166ff440a Add Careerjet-compatible job search params and gap analysis 2026-02-14 15:12:04 -03:00
Tiago Yamamoto
6cd8c02252 feat: add test coverage and handler improvements
- Add new test files for handlers (storage, payment, settings)
- Add new test files for services (chat, email, storage, settings, admin)
- Add integration tests for services
- Update handler implementations with bug fixes
- Add coverage reports and test documentation
2026-01-02 08:50:29 -03:00
Tiago Yamamoto
bb970f4a74 fix(backend): resolve 500 errors on jobs, notifications and secure routes
- Fix CreateJob 500 error by extracting user ID correctly
- Secure Create/Update/Delete Job routes with AuthGuard
- Fix Notifications/Tickets/Profile 500 error (UUID vs Int mismatch)
- Add E2E test for CreateJob
2025-12-24 17:48:06 -03:00
Tiago Yamamoto
0e265e64b8 Refactor backend to use string IDs for Job, Company, and Application 2025-12-23 14:46:17 -03:00
Tiago Yamamoto
28733fff95 feat(tests): �� added unit tests and E2E tests for handlers 2025-12-15 09:08:32 -03:00