Extend Mcp/UseGraphqlQueryFile to cover ee/app/services/mcp/tools
What does this MR do and why?
Adds ee/app/services/mcp/tools/**/* to the Include list of the Mcp/UseGraphqlQueryFile RuboCop cop in .rubocop.yml.
The cop was scoped to app/services/mcp/tools/**/* and ee/app/services/ee/mcp/tools/**/*, but real EE MCP tool services also live under ee/app/services/mcp/tools/ (e.g. ee/app/services/mcp/tools/security/attach_scan_profile_service.rb). The missing glob meant the cop never linted those files, leaving a coverage gap for inline GraphQL operations.
This is a configuration-only change; the cop implementation is unchanged.
Verification:
bundle exec rubocop --only Mcp/UseGraphqlQueryFile ee/app/services/mcp/tools→ 15 files inspected, no offenses detected (all existing tools already useload_graphql).bundle exec rubocop --only Mcp/UseGraphqlQueryFile app/services/mcp/tools ee/app/services/mcp/tools ee/app/services/ee/mcp/tools→ 122 files inspected, no offenses detected.bundle exec rspec spec/rubocop/cop/mcp/use_graphql_query_file_spec.rb→ 7 examples, 0 failures.
References
- Closes #630184 (closed)
- Related: !255760 (adds the sibling
Mcp/VersionedMethodNamingcop, which already covers all three paths)
Screenshots or screen recordings
Not applicable: linting configuration change only.
How to set up and validate locally
- Run the cop against the newly covered directory:
bundle exec rubocop --only Mcp/UseGraphqlQueryFile ee/app/services/mcp/tools - Confirm the cop's effective config now includes the new path:
bundle exec rubocop --show-cops Mcp/UseGraphqlQueryFile - Introduce an inline
graphql_operation:string in a file underee/app/services/mcp/tools/and confirm the cop flags it (revert afterwards).
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.