ci: add Gitea Actions workflow and unit tests
CI / Build & Test (push) Failing after 5s

- Add .gitea/workflows/ci.yml: runs build + tests on push/PR to main
- Add vitest as dev dependency
- Add src/utils.test.ts: 4 tests covering handleTool success, Error throw,
  non-Error throw, and arg passthrough
- Add src/client.test.ts: 12 tests covering URL building, Authorization header,
  query string params, Content-Type presence/absence, error handling with
  message extraction and statusText fallback, and HTTP method correctness

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Space-Banane
2026-06-17 22:09:54 +02:00
parent a1d47d4819
commit 75ecb6232c
4 changed files with 235 additions and 1 deletions
+3 -1
View File
@@ -11,6 +11,7 @@
"build": "tsc",
"dev": "tsc --watch",
"start": "node dist/index.js",
"test": "vitest run",
"prepublishOnly": "pnpm build"
},
"dependencies": {
@@ -19,7 +20,8 @@
},
"devDependencies": {
"@types/node": "^22.19.21",
"typescript": "^5.9.3"
"typescript": "^5.9.3",
"vitest": "^4.1.9"
},
"engines": {
"node": ">=22"