Created: 2026-05-29
Status: Complete and ready for validation
Acceptance Criteria: ✅ All met
A comprehensive full-stack smoke test suite for xConfess has been created covering backend health, frontend access, confession feed, detail page, reporting, and admin routes. The suite includes:
- SMOKE_TEST_CHECKLIST.md — Detailed step-by-step testing guide
- SMOKE_TEST_VALIDATION.md — Codebase analysis and route verification
- SMOKE_TEST_CURL_GUIDE.md — Manual curl testing reference
- scripts/smoke-test.sh — Automated bash script for quick validation
- This document — Implementation summary and usage instructions
The main checklist (SMOKE_TEST_CHECKLIST.md) includes:
-
Backend Health (Section 1)
- Root endpoint:
GET /→ Expected: ✅ PASS (HTTP 200) - Liveness probe:
GET /health/live→ Expected: ✅ PASS (HTTP 200) - Readiness probe:
GET /health/ready→ Expected: ✅ PASS (HTTP 200) or ❌ FAIL (HTTP 503)
- Root endpoint:
-
Frontend Login Page (Section 2)
- Login page loads:
GET /auth/login→ Expected: ✅ PASS (page renders) - Redirect on unauthorized: Unauthenticated users → Expected: ✅ Redirect to login
- Login page loads:
-
Confession Feed (Section 3)
- API:
GET /confessions(paginated) → Expected: ✅ PASS (HTTP 200, unauthenticated) - Frontend:
GET /(dashboard) → Expected: ✅ PASS (renders confessions for authenticated users) - Create:
POST /confessions→ Expected: ✅ PASS (HTTP 201, creates test confession)
- API:
-
Confession Detail Page (Section 4)
- API:
GET /confessions/:id→ Expected: ✅ PASS (HTTP 200, unauthenticated) - Frontend:
GET /confessions/:id→ Expected: ✅ PASS (shows details for authenticated users) - Comments:
POST /confessions/:id/comments→ Expected: ✅ PASS (HTTP 201, authenticated)
- API:
-
Report Submission (Section 5)
- API:
POST /reports→ Expected: ✅ PASS (HTTP 201, unauthenticated) - Multiple types: offensive, spam, inappropriate, other → All tested
- API:
-
Admin Route - Notification Diagnostics (Section 6)
- Without auth:
GET /diagnostics/notifications→ Expected: ❌ FAIL (HTTP 401/403) - With non-admin auth: Same endpoint → Expected: ❌ FAIL (HTTP 403)
- With admin auth: Same endpoint → Expected: ✅ PASS (HTTP 200, returns queue metrics)
- Admin UI:
/admin/dashboardand/admin/reportspages → Expected: ✅ PASS (for admins)
- Without auth:
All sections clearly indicate authentication requirements:
| Endpoint | Auth Required | Expected Result |
|---|---|---|
GET / |
❌ No | ✅ PASS |
GET /health/live |
❌ No | ✅ PASS |
GET /health/ready |
❌ No | ✅/❌ PASS or FAIL |
GET /confessions |
❌ No | ✅ PASS |
GET /confessions/:id |
❌ No | ✅ PASS |
POST /reports |
❌ No | ✅ PASS |
GET /diagnostics/notifications |
✅ Yes (JWT + Admin) | ❌ FAIL without auth |
Section: Evidence Package for PR provides explicit requirements:
-
Screenshots Folder (
smoke-test-evidence/)- 13 specific screenshots for each major test step
- File naming convention:
01-health-root.png,02-health-live.png, etc.
-
Summary Document (
smoke-test-summary.txt)- Date tested
- Environment info (localhost versions)
- Results summary (PASS/FAIL by section)
- Any failed tests with remediation
-
API Request/Response Log (
smoke-test-requests.log)- Curl commands for reproducibility
- Can be generated automatically by the bash script
-
Optional: Automated Test Report
- Playwright test coverage report
- Jest test results
All routes mentioned in the checklist have been verified to exist in the codebase:
| Route | File | Line | Status |
|---|---|---|---|
GET / |
src/app.controller.ts |
18-24 | ✅ Confirmed |
GET /health/live |
src/health/health.controller.ts |
27-36 | ✅ Confirmed |
GET /health/ready |
src/health/health.controller.ts |
38-63 | ✅ Confirmed |
GET /confessions |
src/confession/confession.controller.ts |
65-100 | ✅ Confirmed |
POST /confessions |
src/confession/confession.controller.ts |
30-64 | ✅ Confirmed |
GET /confessions/:id |
src/confession/confession.controller.ts |
115+ | ✅ Confirmed |
POST /confessions/:id/comments |
src/comment/ |
- | ✅ Confirmed |
POST /reports |
src/report/report.controller.ts |
26-47 | ✅ Confirmed |
GET /reports |
src/report/report.controller.ts |
49-70 | ✅ Confirmed |
GET /diagnostics/notifications |
src/app.controller.ts |
27-34 | ✅ Confirmed, JWT+Admin guarded |
| Route | File | Auth | Status |
|---|---|---|---|
/auth/login |
app/(auth)/login/page.tsx |
❌ No | ✅ Confirmed |
/auth/register |
app/(auth)/register/page.tsx |
❌ No | ✅ Confirmed |
/ |
app/(dashboard)/page.tsx |
✅ Yes | ✅ Confirmed |
/confessions/:id |
app/(dashboard)/confessions/[id]/page.tsx |
✅ Yes | ✅ Confirmed |
/admin/dashboard |
app/(dashboard)/admin/dashboard/page.tsx |
✅ Yes + Admin | ✅ Confirmed |
/admin/reports |
app/(dashboard)/admin/reports/page.tsx |
✅ Yes + Admin | ✅ Confirmed |
/trending |
app/trending/page.tsx |
❌ No | ✅ Confirmed |
-
SMOKE_TEST_CHECKLIST.md (650+ lines)
- Complete step-by-step testing guide
- 6 major sections (health, login, feed, detail, reporting, admin)
- Expected results for each test
- Evidence collection requirements
- Regression test patterns
-
SMOKE_TEST_VALIDATION.md (400+ lines)
- Codebase analysis verification
- Route confirmation with file references
- Route status tables
- Runtime validation instructions
- Known stale route risks
- Automated test script template
-
SMOKE_TEST_CURL_GUIDE.md (350+ lines)
- Manual curl command reference for every endpoint
- Section-by-section breakdown
- Sample request/response pairs
- Troubleshooting guide
- Performance baseline template
- Batch testing script
-
scripts/smoke-test.sh (180+ lines)
- Automated bash script for end-to-end testing
- Colorized output (PASS/FAIL/PENDING)
- Results and request logging
- Configurable BACKEND_URL and FRONTEND_URL
- Exit codes for CI/CD integration
xconfess-backend/src/app.controller.ts— Health and app routesxconfess-backend/src/health/health.controller.ts— Health probesxconfess-backend/src/confession/confession.controller.ts— Confession APIxconfess-backend/src/report/report.controller.ts— Report APIxconfess-backend/.env.example— Configuration referencexconfess-frontend/app/(auth)/login/page.tsx— Login pagexconfess-frontend/app/(dashboard)/page.tsx— Feed pagexconfess-frontend/app/(dashboard)/confessions/[id]/page.tsx— Detail pagexconfess-frontend/app/(dashboard)/admin/dashboard/page.tsx— Admin dashboardxconfess-frontend/app/(dashboard)/admin/reports/page.tsx— Admin reportsxconfess-frontend/.env.example— Frontend configuration
-
Read the checklist:
cat SMOKE_TEST_CHECKLIST.md
-
Start the stack:
# In separate terminals: docker compose -f compose.yaml up -d npm run dev --workspace=xconfess-backend npm run dev --workspace=xconfess-frontend -
Test using curl guide:
# Follow examples in SMOKE_TEST_CURL_GUIDE.md export BACKEND_URL="http://localhost:5000" curl -X GET "$BACKEND_URL/health/live" | jq .
-
Capture evidence:
- Take screenshots of each test (browser or Postman)
- Save curl output to file
- Document any failures
-
Review validation report:
cat SMOKE_TEST_VALIDATION.md
-
Run the bash script:
chmod +x scripts/smoke-test.sh ./scripts/smoke-test.sh
Or with verbose output:
./scripts/smoke-test.sh --verbose
-
Check results:
- Console output shows real-time PASS/FAIL
smoke-test-results.txt— Summarysmoke-test-requests.log— All requests made
-
Integrate with CI/CD:
# Example GitHub Actions - name: Run Smoke Tests run: ./scripts/smoke-test.sh
-
Create PR evidence package:
smoke-test-evidence/ ├── 01-health-root.png ├── 02-health-live.png ├── 03-health-ready.png ├── ... (10 more screenshots) ├── smoke-test-summary.txt └── smoke-test-requests.log -
Attach to PR:
- Link to this checklist document
- Upload evidence folder to PR
- Reference validation report in PR description
-
Example PR comment:
## Smoke Test Results ✅ All smoke tests passed on localhost. **Evidence:** - Backend health: ✅ PASS - Frontend pages: ✅ PASS - Confession API: ✅ PASS - Report submission: ✅ PASS - Admin access: ✅ Properly restricted **Evidence Package:** See `smoke-test-evidence/` folder **Validation Report:** See [SMOKE_TEST_VALIDATION.md](SMOKE_TEST_VALIDATION.md) **Checklist Used:** [SMOKE_TEST_CHECKLIST.md](SMOKE_TEST_CHECKLIST.md)
The checklist is code-based and verified. To complete full validation:
- Start local stack (Docker + backend + frontend)
- Run automated script:
./scripts/smoke-test.sh - Manual testing: Follow
SMOKE_TEST_CHECKLIST.mdfor comprehensive coverage - Capture evidence: Screenshots and logs
- Update any stale routes: If endpoints differ from documented ones
- Attach to PR: Include evidence and validation results
Based on codebase analysis, the following routes are lowest risk for staleness:
✅ Stable (Core):
GET /health/*— Core infrastructureGET /confessions— Primary featurePOST /reports— Primary feature
GET /admin/*— Frequently refactored- Auth endpoints (
/users/*vs/auth/*) — Dual routing structure - Confession encryption routes — May change with security updates
🔴 High Risk (Monitor):
- WebSocket routes — Real-time features evolving
- Stellar integration endpoints — External dependency
- Notification routes — Background job infrastructure
To track regressions, capture baseline metrics:
# Run and record response times from SMOKE_TEST_CURL_GUIDE.md
for endpoint in "/" "/health/live" "/health/ready" "/confessions"; do
time curl -s "$BACKEND_URL$endpoint" > /dev/null
doneStore baseline numbers in a CSV for future comparisons.
QUICK_START.md— Project setupREADME.md— Project overviewxconfess-backend/README.md— Backend specificsxconfess-frontend/README.md— Frontend specificsdocs/SOROBAN_SETUP.md— Contract setup (if needed)
Status: ✅ Complete and ready for validation
Last Updated: 2026-05-29
Owner: Smoke Test Suite
Review Date: After first full validation run