🧪 Add tests for get_tool logic#77
Conversation
Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
|
👋 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 New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
There was a problem hiding this comment.
Pull request overview
Adds stronger unit test coverage around src.tools.get_tool to improve confidence in case-insensitive lookup behavior and edge-case handling, while also cleaning up an untracked helper script.
Changes:
- Expanded
test_get_toolto cover mixed casing, empty/whitespace inputs, unknown tools, and duplicate-name first-match behavior. - Standardized quoting/formatting in
tests/test_tools.py. - Removed
patch_pr.pyfrom the repository.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| tests/test_tools.py | Adds new get_tool test cases (mixed casing, edge cases, duplicates) and minor formatting/quote normalization. |
| patch_pr.py | Deletes a one-off patch helper script from the repo root. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| if t.name.lower() == dupe_name.lower() and t != expected_first_module | ||
| ] | ||
| self.assertTrue(len(other_modules) > 0) |
|
Codex Review: Didn't find any major issues. More of your lovely PRs please. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
@copilot, resolve the merge conflicts in this pull request. |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
…detection, assert source_hint in dupe test Agent-Logs-Url: https://github.com/badMade/claw-code/sessions/7e6aed0f-9e29-4fe8-b6ea-7f90c4edbeab Co-authored-by: badMade <106821302+badMade@users.noreply.github.com>
Agent-Logs-Url: https://github.com/badMade/claw-code/sessions/7e6aed0f-9e29-4fe8-b6ea-7f90c4edbeab Co-authored-by: badMade <106821302+badMade@users.noreply.github.com>
Merged Also took the opportunity to address the two reviewer comments on the duplicate-name test: switched to |
|
@gemini-code-assist, what are the steps and line numbers to make this fix? |
|
To address the merge conflicts and implement the requested improvements in 1. Optimization of
|
|
@copilot, resolve the merge conflicts in this pull request. |
🎯 What: Added tests for the
get_toolfunction insrc/tools.pyas it was lacking coverage.📊 Coverage: The test module now thoroughly tests for basic matches, mixed casing, various edge cases (empty strings, whitespace), unknown tools, and importantly, first-match priority behaviour when multiple tools share the same name in
PORTED_TOOLSsnapshot.✨ Result: Test coverage and reliability of
get_toolis improved and clearly documented.PR created automatically by Jules for task 8720967847253227231 started by @badMade