test-radar

A test workflow for Radar that builds the application, starts a real local server, and checks its API, with optional browser tests through Playwright.

In plain words
What is it for?
Creating tests from the files changed, checking API responses, and running end-to-end browser tests when the required Playwright connection is available.
Why use it?
It checks whether changes work in a running application instead of relying only on code inspection or isolated tests.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/skyhook-io/radar/test-radar
Clone the repo
git clone --depth 1 https://github.com/skyhook-io/radar

Made for: Claude Code.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 730 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00730
Opus 5 $0.00000 $0.00365
Sonnet 5 $0.00000 $0.00146
Haiku 4.5 $0.00000 $0.00073

Measured 3d ago against content hash d69197cfdd0a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

test-radar scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

3. **Start server**: Run the built binary with `--port <random-port> --no-open` in the background. Wait for it to be ready (curl the health endpoint or `/api/cluster-info`).
.claude/commands/test-radar.md · 50 lines

How it starts

The opening of the file, as written. The whole thing — 50 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Test Radar

Build and test Radar changes using a real running instance. Combines build verification, API smoke tests, and optional Playwright E2E tests.

Prerequisites

Playwright MCP: Check if the Playwright MCP tools are available (e.g., mcp__playwright__browser_navigate). If NOT available, tell the user "Playwright MCP is not available — please add it to your MCP config and restart" and stop. Do not attempt workarounds.

Setup

  1. Pick a random port (e.g., 9300-9399 range) for the backend to avoid conflicting with other running Radar instances.
  2. Build: Run make build from the repo root. If it fails, diagnose and report — do not proceed.
  3. Start server: Run the built binary with --port <random-port> --no-open in the background. Wait for it to be ready (curl the health endpoint or /api/cluster-info).

Test Plan

Create a test plan based on the current changes (check git diff main..HEAD --name-only to scope what changed). Then execute what you can autonomously.

What to test yourself:

  • API smoke tests: Hit key API endpoints via curl/fetch and verify they return valid responses (200, correct JSON structure). Good candidates: /api/cluster-info, /api/resource-counts, /api/resources/pods, /api/dashboard, /api/events/stream (SSE — connect briefly, verify event format).
  • Frontend loads: Use Playwright to navigate to http://localhost:<port>, verify the page loads without console errors, key UI elements render.
  • Feature-specific tests: Based on the diff, test the specific feature that changed. For SSE-related changes, connect to the SSE stream and verify events arrive. For UI changes, use Playwright to verify rendering. For API changes, hit the relevant endpoints.

What to flag for manual testing:

  • Anything requiring kubectl commands against a live cluster (you don't know if one is connected)
  • Destructive operations (creating/deleting K8s resources)
  • Visual/UX verification that can't be checked programmatically
  • Multi-browser or performance testing

Read the full file on GitHub · 50 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 50 lines · 0 tokens per session scan A d69197cfdd0a

Subscribe to this mod's changes

test-radar is a command published in the GitHub repository skyhook-io/radar (3,204 stars, last pushed yesterday), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 730 tokens. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.