cd /news/ai-agents/test-a-web-app-built-with-claude-cod… · home › topics › ai-agents › article
[ARTICLE · art-175272] src=dev.to ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

Test a web app built with Claude Code in 5 minutes

A developer demonstrated a workflow in which Claude Code uses Kane CLI, a browser-automation testing tool from TestMu AI, to verify running web apps end to end. The CLI installs globally via npm, runs user flows described in plain English in a real browser, and returns pass/fail through exit codes (0 pass, 1 fail, 2 setup error, 3 timeout) plus NDJSON events and saved evidence files. A companion Claude Code skill lets the agent run the checks itself, read results, and fix failures in the same session, with headless runs and exit-code gating intended for CI.

recommendation

After Claude Code edits a web app, have it run a Kane CLI browser flow for the changed user path and gate CI on the exit code, keeping credentials in a gitignored variables file.

more in playbook: Working with AI coding agents
read4 min views2 publishedNov 24, 2026

Claude Code edits real code and it compiles, but a green build is not a working web app. An edit drifts a type, touches a file you didn't ask about, or leaves a form that no longer submits, and the build stays green. The diff shows what moved, not whether the flow still works.

Kane CLI drives your running web app in a real browser, checks each step of a flow you describe in plain English, and returns a pass or fail. In this tutorial, Claude Code runs that check itself.

Not for unit tests: Claude Code already runs pytest, vitest or jest on its own. Kane CLI covers the layer those runners cannot reach: it opens the app in a real browser and reports whether the user flow works.

http://localhost:3000; change the URL to yours. The CLI is free to install. Runs use KaneAI credits. As of November 2026, you can start free with 10,000 credits, valid for 30 days.

npm install -g @testmuai/kane-cli
kane-cli login --oauth   # opens the sign-in page in your browser
kane-cli whoami          # confirms you are signed in

There is nothing to wire into your repo or build config.

npx @testmuai/kane-cli-skill

This installs the skill to ~/.claude/skills/kane-cli/. The skill teaches Claude Code when to call Kane CLI and how to read the result. If Claude Code is already running, restart it so it loads the skill. The skill docs cover installing it for one project only.

The flow signs in, so put a test account's credentials in a variables file instead of the chat. Create .testmuai/variables/local.json, fill in the values yourself, and keep the file out of git:

{
  "username": { "value": "" },
  "password": { "value": "", "secret": true }
}

Start your app, then give Claude Code this prompt:

Open the running web app, sign in, add a task, mark it done, and confirm it
persists after a refresh. Use kane-cli. The app is at http://localhost:3000.
Sign in with {{username}} and {{password}} from .testmuai/variables/local.json.

On the first request, Claude Code runs a ready check to confirm Kane CLI is installed and signed in. Then it runs the flow.

[RUN 1: screenshot of the prompt and the ready check in Claude Code]

By default the browser opens in a visible window, so you can watch. A run takes from 30 seconds to a few minutes.

[RUN 2: screenshot of the browser partway through the flow]

When it finishes, Claude Code shows a result card.

[RUN 3: screenshot of the result card]

[RUN 4: paste the command Claude Code ran, then the final run_end line. Remove the account name, project links and local paths. Give the real duration and credits used, e.g. "Our run took __ seconds and used __ credits."]

Kane CLI returns one JSON event per line (NDJSON) and an exit code:

Exit code Meaning
0 Pass
1 Fail
2 Setup or auth error; nothing ran
3 Timeout or cancelled

One thing to know about code 1: it also covers a start URL that doesn't load. If the app isn't running, you get a 1, not a 2, and the run still uses credits. Check that the URL opens before you start.

Every run also saves a .evidence file with the step-by-step trace, screenshots, video and logs, so there is proof behind the verdict.

Once the skill is in place, ask in plain words:

Fix the coupon bug and verify it in a browser.

Claude Code makes the change, runs the flow, reads the result and fixes what failed, in one session. Two habits help:

Authenticate with your TestMu AI credentials, pass --headless and --timeout, and gate on the exit code:

kane-cli run "Go to $APP_URL and verify the task list is visible" \
  --agent --headless --timeout 180 \
  --username "$LT_USERNAME" --access-key "$LT_ACCESS_KEY"

Keep the credentials in your CI secret store. A non-zero exit code fails the job.

Kane CLI checks the flow you describe, in a real browser: sign-in, forms, data that has to survive a refresh. It does not replace unit tests, and it won't check a flow nobody described. Start with the one or two journeys that would hurt most if they broke.

Based on our page Test web apps built with Claude Code.

── more in #ai-agents 4 stories · sorted by recency
── more on @claude code 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/test-a-web-app-built…] indexed:0 read:4min 2026-11-24 · —