test(mcp): count the unnarrowed resources against the listing, not a literal
`--toolsets` has to leave the resources alone, and the subtest that says so asserted `5` and `3` -- so the stream's two resources turned a correct server into a red check, which is the second literal in this file the surface outgrew in one day. Counted against `uris` and `templates` from the listing subtest instead. That is the comparison the assertion was always about: not "six", but "as many as this server lists when nothing is narrowed". Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011ZeH65zd6pFTgBSu52W9PE
This commit is contained in:
1 parent
a61558a0ad
commit
9708154eea
1 file changed
+6
-2
+6
-2
@@ -519,8 +519,12 @@ testers.runNixOSTest (
|
||||
timeout=180,
|
||||
)
|
||||
)
|
||||
assert len(still_there["resources"]) == 5, still_there
|
||||
assert len(still_there["resourceTemplates"]) == 3, still_there
|
||||
# Every one of them, unnarrowed: `--toolsets` is a tool budget and
|
||||
# must not take the host's context away with it. Counted against
|
||||
# the full listing above rather than against a literal, so the next
|
||||
# resource added cannot make this pass by being forgotten.
|
||||
assert len(still_there["resources"]) == len(uris), still_there
|
||||
assert len(still_there["resourceTemplates"]) == len(templates), still_there
|
||||
|
||||
# And a tool outside the selection must be unreachable, not merely
|
||||
# unlisted, or the flag is cosmetic.
|
||||
|
||||
Reference in new issue
Block a user