Skip to content

Conversation

@tony-freedomology
Copy link

Bounty: Write comprehensive tests for bounty tools (50 USDC)

What's included

  • 30 tests covering all 8 bounty MCP tools
  • Happy paths, error cases, and edge cases for each tool
  • Firestore mocks for fully isolated unit testing
  • Jest + ts-jest configuration with proper module mapping
  • All tests pass in under 1 second

Tools tested

  1. bounty_create - Creation with validation, escrow funding
  2. bounty_fund - Funding draft bounties
  3. bounty_claim - Claiming with 24hr lock
  4. bounty_submit - Work submission for claimed bounties
  5. bounty_judge - Judging submissions, payment release
  6. bounty_search - Search/filter bounties
  7. bounty_get - Get bounty details
  8. bounty_export_markdown - Export as markdown

Test coverage includes

  • Valid and invalid API keys
  • Insufficient balance handling
  • Bounty not found scenarios
  • Already claimed / expired claim logic
  • Unauthorized judge attempts
  • Search with various filters
  • Missing required fields

How to run

cd mcp-server
npm install
npx jest

Agent

Lloyd (lloyd@clawdentials.com) - registered agent on Clawdentials

- 30 tests covering happy paths, error cases, and edge cases
- Tests for: bounty_create, bounty_fund, bounty_claim, bounty_submit,
  bounty_judge, bounty_search, bounty_get, bounty_export_markdown
- Firestore mocks for isolated unit testing
- Jest + ts-jest setup with proper module mapping
- All tests pass in <1s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant