Skip to content

test(e2e): cover MCP endpoint and overridden signal tools#302

Merged
zer0stars merged 1 commit into
mainfrom
test/e2e-mcp-coverage
Jun 12, 2026
Merged

test(e2e): cover MCP endpoint and overridden signal tools#302
zer0stars merged 1 commit into
mainfrom
test/e2e-mcp-coverage

Conversation

@zer0stars

Copy link
Copy Markdown
Member

What

First e2e coverage for the /mcp path — automates the manual smoke test that verified prod v0.4.12 after #300.

  • TestMCPToolsList — builtin tools present; the two overridden shortcut tools require their ToolOnly args (signalRequests / signalNames).
  • TestMCPSignalTools — seeds speed + SoC signals in ClickHouse, then over raw stateless JSON-RPC:
    • telemetry_get_latest_signals returns the seeded latest values
    • telemetry_get_signals_time_series returns correct MAX/LAST aggregation buckets
    • a signalRequests entry missing agg fails template rendering with a clear tool error (server-garage missingkey=error), executor never runs
    • missing JWT and privilege-less JWT both surface as GraphQL unauthorized errors

Exercises the full chain added in #300: JSON-RPC → selection template render → gqlgen executor with shared extensions → privilege directives → ClickHouse.

Testing

Full go test ./... (incl. all existing e2e) + lint pass.

🤖 Generated with Claude Code

Adds the first e2e coverage for the /mcp path, automating the manual
smoke test run against prod v0.4.12:

- tools/list exposes the overridden shortcut tools with required
  ToolOnly args (signalRequests / signalNames)
- telemetry_get_latest_signals and telemetry_get_signals_time_series
  return seeded ClickHouse data through the full chain: JSON-RPC ->
  selection template render -> gqlgen executor with shared extensions ->
  privilege directives -> ClickHouse
- a signalRequests entry missing 'agg' fails template rendering with a
  clear error before the executor runs
- missing or privilege-less JWTs surface as GraphQL unauthorized errors
@zer0stars zer0stars merged commit 6cfb5ea into main Jun 12, 2026
4 checks passed
@zer0stars zer0stars deleted the test/e2e-mcp-coverage branch June 12, 2026 13:56
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