#!/usr/bin/env bash
# Run from either installed checkout with its isolated dev server running.
set -eu
fixture=$(mktemp -d)
git init -q "$fixture"
node apps/server/src/bin.ts project add "$fixture" --title 'Fruit report' --base-dir .t3
node apps/server/src/bin.ts thread start "$fixture" "Call the Agent tool once with subagent_type general-purpose, run_in_background false, and this prompt: 'Call the Agent tool once with subagent_type general-purpose, run_in_background false, and the prompt: Reply with a markdown bullet list of three fruits, one per line, and nothing else. Then reply with exactly what that agent said.' Then reply with exactly what that agent said." --provider claudeAgent --model haiku --title 'Nested fruit report' --base-dir .t3 --wait --json
# Pair a browser using `node apps/server/src/bin.ts pair --base-dir .t3`.
# Open the returned thread, expand Worked for, then 2 subagents.
# Inspect List three fruits, then click it to inspect the child final message.
# Captures: Chromium, light theme, 1280x800 CSS pixels, device scale factor 2.
# Both dev servers were started with T3CODE_DEV_SEED=0, using fresh databases.
