claude-print/tests/fixtures/transcript_v2.1.168.jsonl
jedarden 50b213285a Add Phase 9: NEEDLE integration — install.sh, claude-print.yaml, --check subcommand
- claude-print.yaml: NEEDLE agent config with stdin input_method, needle-transform-claude
  output_transform, and invoke_template for subscription-billed claude-print runs
- install.sh: download release binary from GitHub, backup existing, install mock_claude,
  install NEEDLE config if present, run --check to verify, print --version
- src/check.rs: --check doctor subcommand with openpty probe, mkfifo probe, and optional
  mock_claude PTY round-trip (skipped if mock_claude not in PATH)
- src/main.rs + src/lib.rs: wire up check::run() for --check flag
- README.md: add Install, Usage, Flags table (matches --help exactly), Exit codes,
  and NEEDLE integration sections
- test-fixtures/mock-claude: extend with all MOCK_* env var controls needed for
  integration tests (MOCK_SILENT, MOCK_EXIT_BEFORE_STOP, MOCK_TRUST_DIALOG, etc.)
- tests/cli.rs, tests/hooks.rs, tests/version_compat.rs: Phase 10 unit test stubs

claude-print --check passes: openpty PASS, mkfifo PASS, mock_claude PTY PASS
bash -n install.sh: syntax OK

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-10 01:36:28 -04:00

5 lines
1.3 KiB
JSON

{"type":"assistant","message":{"id":"msg-001","content":[{"type":"text","text":"This is a test response"}],"usage":{"input_tokens":6178,"output_tokens":295,"cache_creation_input_tokens":825,"cache_read_input_tokens":26442,"server_tool_use":{"web_search_requests":0,"web_fetch_requests":0},"service_tier":"standard","cache_creation":{"ephemeral_5m_input_tokens":0,"ephemeral_1h_input_tokens":825},"inference_geo":"","speed":"standard"}}}
{"type":"assistant","message":{"id":"msg-002","content":[{"type":"text","text":"chunk1 "}],"usage":{"input_tokens":100,"output_tokens":50,"cache_creation_input_tokens":0,"cache_read_input_tokens":5000,"server_tool_use":{"web_search_requests":0,"web_fetch_requests":0},"service_tier":"standard","speed":"standard"}}}
{"type":"assistant","message":{"id":"msg-002","content":[{"type":"text","text":"chunk2 "}],"usage":{"input_tokens":100,"output_tokens":50,"cache_creation_input_tokens":0,"cache_read_input_tokens":5000,"service_tier":"standard","speed":"standard"}}}
{"type":"assistant","message":{"id":"msg-002","content":[{"type":"text","text":"chunk3"}],"usage":{"input_tokens":100,"output_tokens":50,"cache_creation_input_tokens":0,"cache_read_input_tokens":5000,"service_tier":"standard","speed":"standard"}}}
{"type":"result","is_error":false,"session_id":"test-session-v2168","duration_ms":1234}