Skip to content

test(AIC-3737): cover tools in the handler-owned settings test - #276

Open
jeffdupont wants to merge 1 commit into
mainfrom
jdupont/aic-3737-owned-tools-test
Open

jeffdupont wants to merge 1 commit into
mainfrom
jdupont/aic-3737-owned-tools-test

Conversation

@jeffdupont

@jeffdupont jeffdupont commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The claude-messages handler takes model, the messages, the system prompt and tools from the config, never from model.parameters. The existing test (test_config_cannot_override_model_or_messages) covered every one except tools. This PR adds tools:

  • The config offers one tool (search), and model.parameters sets a different tools list.
  • The test asserts that the provider call's tools holds only search, and that the parameters' tool appears nowhere in the call arguments.

No handler code changes.

Tests

  • uv run ruff check ., uv run ruff format --check .: pass.
  • uv run pytest packages/claude-messages: 171 passed.

🤖 Generated with Claude Code


Note

Overview
Extends test_config_cannot_override_model_or_messages so tools is covered the same way as model, messages, and system: the test config defines a search tool while model.parameters tries to inject a different tools list.

The new assertions check that messages.create receives only search from top-level config and that the parameters tool never appears in the call kwargs.

No handler or production code changes—this only locks in existing handler-owned tools behavior.

Reviewed by Cursor Bugbot for commit c73a3d0. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jeffdupont
jeffdupont marked this pull request as ready for review November 4, 2026 19:55
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