test(auth): add health endpoint unit tests

- Add node:test suite for auth health endpoint covering:
  - 200 with db=reachable when pool.connect succeeds
  - 503 with db=unreachable when pool.connect throws
  - 503 with db=unreachable when query times out
- Add test script to auth/package.json
- Merge dev to resolve 3-commit divergence

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
2026-05-04 15:40:04 +00:00
committed by Barcode Betty [agent]
parent 2a7f1921b0
commit 3ac61908f5
2 changed files with 102 additions and 1 deletions
+2 -1
View File
@@ -7,7 +7,8 @@
"dev": "tsx watch src/index.ts",
"build": "tsc",
"start": "node dist/index.js",
"generate": "npx @better-auth/cli generate"
"generate": "npx @better-auth/cli generate",
"test": "node --test src/__tests__/*.test.ts"
},
"dependencies": {
"bcrypt": "^6.0.0",