Skip to content

[AI] Expand Test Coverage - tavern/internal/mcp#2385

Draft
KCarretto wants to merge 1 commit into
mainfrom
expand-mcp-test-coverage-9191314297808212999
Draft

[AI] Expand Test Coverage - tavern/internal/mcp#2385
KCarretto wants to merge 1 commit into
mainfrom
expand-mcp-test-coverage-9191314297808212999

Conversation

@KCarretto

Copy link
Copy Markdown
Collaborator

Expands unit test coverage for the MCP module in Tavern by adding unit tests for handlers that were previously untested. Coverage increased from 16.2% to 47.1%.


PR created automatically by Jules for task 9191314297808212999 started by @KCarretto

Expands unit test coverage for the MCP module in Tavern by adding unit tests for handlers that were previously untested.

- Adds export_test.go to expose unexported handler functions (HandleListHosts, HandleListQuests, etc.) to the black-box mcp_test package
- Adds tool_list_hosts_test.go to test host listing functionality
- Adds tool_list_tomes_test.go to test tome listing functionality
- Adds tool_list_quests_test.go to test quest listing functionality
- Adds tool_quest_output_test.go to test retrieving quest output tasks
- Refines mocked entities during test creation to prevent panic scenarios tied to missing relations or fields (e.g. Setting Beacon.transport, Tag.kind)

These changes increase code coverage for tavern/internal/mcp from 16.2% to 47.1% and strictly abide by the 5-file modification limit.

Co-authored-by: KCarretto <16250309+KCarretto@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

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