test: add 106 unit + smoke tests, 93% coverage

- pytest + respx + pytest-cov added as dev dependencies
- tests/smoke/test_registration.py: verify all 66 tools registered and unique
- tests/unit/: 12 files covering every tool — HTTP method, URL, params/body, errors
- tests/config.test.json + conftest.py: zero-network test setup via GITEA_CONFIG
- CLAUDE.md: developer guide with testing philosophy, pyramid, and commands
- server/gitea_mcp.py: get_commit, list_pr_files tools added
- README.md: tool count corrected to 66
This commit is contained in:
2026-06-08 09:09:44 +03:00
parent 50cd8e85e6
commit a6162a855c
23 changed files with 1722 additions and 4 deletions
+4 -4
View File
@@ -1,6 +1,6 @@
# gitea-platform-mcp
Full Gitea platform management — 50 tools for repositories, issues, PRs, branches, files, releases, webhooks, and organizations.
Full Gitea platform management — 66 tools for repositories, issues, PRs, branches, files, releases, webhooks, and organizations.
## Setup (one-time)
@@ -55,7 +55,7 @@ After installing, ask: "проверь подключение к Gitea" — Clau
- `uv` installed (https://docs.astral.sh/uv/)
- Gitea instance accessible from your computer
## Tools (50)
## Tools (66)
| Category | Tools |
|----------|-------|
@@ -65,9 +65,9 @@ After installing, ask: "проверь подключение к Gitea" — Clau
| Files | list_directory, get_file, create_file, update_file, delete_file |
| Issues | list_issues, get_issue, create_issue, update_issue, close_issue, reopen_issue, list_issue_comments, add_issue_comment, edit_issue_comment, delete_issue_comment |
| Labels & Milestones | list_labels, create_label, add_issue_labels, list_milestones, create_milestone |
| Pull Requests | list_pull_requests, get_pull_request, create_pull_request, update_pull_request, merge_pull_request, get_pr_diff, list_pr_reviews, create_pr_review |
| Pull Requests | list_pull_requests, get_pull_request, create_pull_request, update_pull_request, merge_pull_request, get_pr_diff, list_pr_files, list_pr_reviews, create_pr_review |
| Releases | list_releases, get_latest_release, create_release, delete_release |
| Webhooks | list_repo_webhooks, create_repo_webhook, delete_repo_webhook |
| Users & Orgs | get_user, search_users, list_my_orgs, get_org, list_org_repos, list_org_members, list_org_teams |
| Commits | list_commits, compare_branches, list_repo_contributors |
| Commits | list_commits, get_commit, compare_branches, list_repo_contributors |
| Notifications | list_notifications, mark_all_notifications_read |