diff --git a/ISSUE-005.md b/ISSUE-005.md new file mode 100644 index 0000000..a87ba65 --- /dev/null +++ b/ISSUE-005.md @@ -0,0 +1,42 @@ +# Issue #5: Implement comprehensive unit tests for all API endpoints + +## Beschreibung +Wir benötigen umfassende Unit-Tests für alle API-Endpunkte, um die Funktionalität und Stabilität des Backends zu gewährleisten. Die Tests sollen sowohl positive als auch negative Szenarien abdecken. + +## Akzeptanzkriterien +- [x] Alle vorhandenen API-Endpunkte sind mit Unit-Tests versehen +- [x] Testabdeckung für alle Rollen (user, moderator, admin) +- [x] Tests für Fehlerfälle und Validierungsfehler +- [x] Integration in CI/CD-Pipeline + +## Tasks +- [x] Erstellen eines strukturierten Test-Frameworks +- [x] Implementieren von Unit-Tests für Auth-Endpunkte +- [x] Implementieren von Unit-Tests für Request-Endpunkte +- [x] Implementieren von Unit-Tests für Offer-Endpunkte +- [x] Implementieren von Unit-Tests für Deal-Endpunkte +- [x] Implementieren von Unit-Tests für Address-Endpunkte +- [x] Implementieren von Unit-Tests für Contact-Endpunkte +- [x] Implementieren von Unit-Tests für Review-Endpunkte +- [x] Implementieren von Unit-Tests für Dispute-Endpunkte +- [x] Integration der Tests in das Build-Prozess + +## Dokumentation +- Relevantes Dokument: docs/roles-and-permissions.md +- Link zur API-Dokumentation: openapi.yaml + +## Abhängigkeiten +- Backend-Struktur ist implementiert +- Rollen- und Rechtekonzept ist definiert + +## Priorität +- [ ] Low +- [x] Medium +- [ ] High +- [ ] Critical + +## Labels +- [x] enhancement +- [ ] bug +- [x] documentation +- [x] security \ No newline at end of file diff --git a/ISSUE-TEMPLATE.md b/ISSUE-TEMPLATE.md index 7470c90..f1e44a4 100644 --- a/ISSUE-TEMPLATE.md +++ b/ISSUE-TEMPLATE.md @@ -1,22 +1,34 @@ -## Issue Description +## Issue Template -This issue tracks the implementation of role-based access control (RBAC) for the helpyourneighbour project. +### Beschreibung +Kurze Beschreibung des Problems oder der Aufgabe. -## Acceptance Criteria +### Akzeptanzkriterien +- [ ] Kriterium 1 +- [ ] Kriterium 2 +- [ ] Kriterium 3 -- [ ] Role middleware is implemented and tested -- [ ] All routes are properly protected by role checks -- [ ] Audit logging is implemented for sensitive actions -- [ ] Documentation is updated with the new RBAC implementation +### Tasks +- [ ] Task 1 +- [ ] Task 2 +- [ ] Task 3 -## Tasks +### Dokumentation +- Relevantes Dokument: +- Link zur API-Dokumentation: -1. Implement role middleware in `backend/middleware/role.middleware.js` -2. Create tests for role middleware in `backend/tests/roles.test.js` -3. Update existing routes to use role middleware -4. Add audit logging for sensitive actions -5. Update documentation in `docs/roles-and-permissions.md` +### Abhängigkeiten +- Abhängigkeit 1 +- Abhängigkeit 2 -## Notes +### Priorität +- [ ] Low +- [ ] Medium +- [ ] High +- [ ] Critical -This issue is a follow-up to the discussion in #42 and aims to implement the role-based access control system as described in the documentation. \ No newline at end of file +### Labels +- [ ] enhancement +- [ ] bug +- [ ] documentation +- [ ] security \ No newline at end of file