feat(budget): add cost reporting to plan status and session show CLI output #10616

Merged
HAL9000 merged 6 commits from feat/v3.6.0/cost-reporting-cli into master 2026-06-14 22:34:02 +00:00
3 changed files with 369 additions and 0 deletions
+32
View File
@@ -0,0 +1,32 @@
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Feature: Cost reporting in plan status and session show CLI output
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
As a user
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
I want to see cost information in the plan status and session show commands
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
So that I can track how much I've spent on plans and sessions
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Scenario: Plan status JSON output includes cost field
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Given a plan status CLI runner with mocked service
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And a plan exists with cost metadata
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Review

The When steps need matching step definitions. Consider using the same pattern as other CLI feature files: actual CLI invocation via CliRunner with real command arguments.

The When steps need matching step definitions. Consider using the same pattern as other CLI feature files: actual CLI invocation via CliRunner with real command arguments.
When I run plan status --format json for the plan
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Then the JSON output contains a "cost" field
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And the cost field contains cost metadata
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Scenario: Session show JSON output includes estimated cost
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Given a session show CLI runner with mocked service
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And a session exists with token usage
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
When I run session show --format json for the session
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Then the JSON output contains "estimated_cost" field
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And the estimated_cost is properly formatted as currency
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Scenario: Plan status rich output displays cost panel
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Given a plan status CLI runner with mocked service
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And a plan exists with cost metadata
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
When I run plan status for the plan with cost reporting
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Then the output contains cost information
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And the cost information is properly formatted
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Scenario: Session show rich output displays cost information
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Given a session show CLI runner with mocked service
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And a session exists with token usage
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
When I run session show for the session
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
Then the output contains cost information
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
And the cost information is properly formatted
Review

BLOCKING: All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" which have no @when step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI unit_tests job is red because of this.

BLOCKING: All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` which have no `@when` step implementations. This causes Behave to fail with StepDefinitionNotFoundError — the CI `unit_tests` job is red because of this.
+335
View File
@@ -0,0 +1,335 @@
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Step implementations for cost reporting in CLI output.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

Suggestion: The existing test files (session_cli_steps.py, plan_cli_coverage_r3_steps.py) use CliRunner + CliRunner.invoke(app, [...]) pattern and real mock objects. Rewrite these Given steps to create real plan session objects or mock services, similar to _make_session() in session_cli_steps.py.

Suggestion: The existing test files (session_cli_steps.py, plan_cli_coverage_r3_steps.py) use `CliRunner` + `CliRunner.invoke(app, [...])` pattern and real mock objects. Rewrite these Given steps to create real plan session objects or mock services, similar to `_make_session()` in session_cli_steps.py.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Tests for ``agents plan status`` and ``agents session show`` commands,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
verifying that cost information is correctly reported in both JSON and
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
rich output formats.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from __future__ import annotations
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: No @when decorators are defined in this file. The feature file has 4 When steps ("When I run "agents plan status..."" and "When I run "agents session show..."") but there are no corresponding step implementations. This will cause Behave to fail every scenario with an undefined step error.

BLOCKING: No @when decorators are defined in this file. The feature file has 4 When steps ("When I run \"agents plan status...\"" and "When I run \"agents session show...\"") but there are no corresponding step implementations. This will cause Behave to fail every scenario with an undefined step error.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
import json
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from datetime import datetime
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from typing import Any
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from unittest.mock import MagicMock, patch
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from behave import given, then, when
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from behave.runner import Context
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from typer.testing import CliRunner
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from ulid import ULID
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from cleveragents.cli.commands import session as session_mod
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from cleveragents.cli.commands.plan import app as plan_app
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from cleveragents.cli.commands.session import app as session_app
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from cleveragents.domain.models.core.cost_metadata import CostMetadata
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from cleveragents.domain.models.core.plan import (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
NamespacedName,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Plan,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
PlanIdentity,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: These Then steps check context.json_output which is never set by any step. The existing tests use context.result" and context.result.output. Rewrite the Then steps to match the existing convention. Example from session_cli_steps.py: json.loads(context.result.output)`.

BLOCKING: These Then steps check `context.json_output` which is never set by any step. The existing tests use `context.result" and `context.result.output`. Rewrite the Then steps to match the existing convention. Example from session_cli_steps.py: `json.loads(context.result.output)`.
PlanPhase,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
ProcessingState,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
from cleveragents.domain.models.core.session import Session, SessionTokenUsage
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ULID constants shared across scenarios
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
_PLAN_ID = str(ULID())
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
_SESSION_ID = str(ULID())
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
_ENVELOPE_KEYS = {"command", "status", "exit_code", "data", "timing", "messages"}
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def _unwrap_envelope(parsed: Any) -> Any:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Return the ``data`` field if *parsed* is a spec envelope, else *parsed* as-is."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
if isinstance(parsed, dict) and _ENVELOPE_KEYS.issubset(parsed.keys()):
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
return parsed["data"]
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
return parsed
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def _make_plan_with_cost(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
*,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan_id: str | None = None,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
cost_metadata: CostMetadata | None = None,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
) -> Plan:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Create a test Plan with cost metadata.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Args:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan_id: Optional plan ULID; generates one if omitted.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
cost_metadata: Optional CostMetadata; creates one with sample data if omitted.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Returns:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
A fully constructed Plan with cost tracking.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
return Plan(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
identity=PlanIdentity(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan_id=plan_id or str(ULID()),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
root_plan_id=plan_id or str(ULID()),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
namespaced_name=NamespacedName.parse("local/test-plan"),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
description="Test plan for cost reporting",
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
action_name="local/test-action",
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
phase=PlanPhase.EXECUTE,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
processing_state=ProcessingState.PROCESSING,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
cost_metadata=cost_metadata
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
or CostMetadata(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
total_tokens=1500,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
input_tokens=1000,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
output_tokens=500,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
total_cost=0.045,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
budget_remaining=95.0,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
provider_costs={"openai": 0.035},
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def _make_session_with_tokens(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
*,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_id: str | None = None,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
token_usage: SessionTokenUsage | None = None,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
) -> Session:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Create a test Session with token usage / cost data.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Args:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_id: Optional session ULID; generates one if omitted.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
token_usage: Optional SessionTokenUsage; creates one with sample data if omitted.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Returns:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
A fully constructed Session with token usage tracking.
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
return Session(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_id=session_id or str(ULID()),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
actor_name="openai/gpt-4",
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
namespace="local",
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
messages=[],
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
token_usage=token_usage
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
or SessionTokenUsage(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
input_tokens=200,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
output_tokens=150,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
estimated_cost=0.008,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
created_at=datetime.now(),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
updated_at=datetime.now(),
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Setup
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@given("a plan status CLI runner with mocked service")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_plan_cli_runner(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Set up CLI runner with a mocked lifecycle service for plan status."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.runner = CliRunner()
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service = MagicMock()
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.plan_id = _PLAN_ID
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Default: get_plan returns a plan with cost metadata
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
default_plan = _make_plan_with_cost(plan_id=_PLAN_ID)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get_plan.return_value = default_plan
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Patch the module-level service accessor, restoring original on cleanup
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
_patcher = patch(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"cleveragents.cli.commands.plan._get_lifecycle_service",
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
return_value=context.mock_service,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
_patcher.start()
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.add_cleanup(_patcher.stop)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@given("a session show CLI runner with mocked service")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_session_cli_runner(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Set up CLI runner with a mocked session service for session show."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.runner = CliRunner()
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service = MagicMock()
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.session_id = _SESSION_ID
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Default: get returns a session with token usage / cost
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
default_session = _make_session_with_tokens(session_id=_SESSION_ID)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get.return_value = default_session
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Patch the module-level service accessor
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_mod._service = context.mock_service # type: ignore[assignment]
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def cleanup() -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_mod._service = None # type: ignore[assignment]
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.add_cleanup(cleanup)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Given: domain objects with cost data
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@given("a plan exists with cost metadata")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_plan_with_cost_metadata(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Create a test Plan with cost metadata and register it on the service."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
cost_meta = CostMetadata(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
total_tokens=2000,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
input_tokens=1400,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
output_tokens=600,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
total_cost=0.06,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
budget_remaining=40.0,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
provider_costs={"openai": 0.04, "anthropic": 0.02},
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan = _make_plan_with_cost(plan_id=_PLAN_ID, cost_metadata=cost_meta)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get_plan.return_value = plan
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.plan_id = _PLAN_ID
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@given("a session exists with token usage")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_session_with_token_usage(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Create a test Session with token usage data and register it on the service."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
token_usage = SessionTokenUsage(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
input_tokens=300,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
output_tokens=200,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
estimated_cost=0.012,
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session = _make_session_with_tokens(session_id=_SESSION_ID, token_usage=token_usage)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get.return_value = session
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.session_id = _SESSION_ID
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# When: CLI command invocations
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@when("I run plan status --format json for the plan")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_plan_status_json(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Execute ``plan status <id> --format json`` and store the result."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan_id = context.plan_id
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan = _make_plan_with_cost(plan_id=plan_id)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get_plan.return_value = plan
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.result = context.runner.invoke(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan_app, ["status", plan_id, "--format", "json"]
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@when("I run session show --format json for the session")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_session_show_json(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Execute ``session show <id> --format json`` and store the result."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_id = context.session_id
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session = _make_session_with_tokens(session_id=session_id)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get.return_value = session
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.result = context.runner.invoke(
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_app, ["show", session_id, "--format", "json"]
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@when("I run plan status for the plan with cost reporting")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_plan_status_rich(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Execute ``plan status <id>`` (rich output) and store the result."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan_id = context.plan_id
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
plan = _make_plan_with_cost(plan_id=plan_id)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get_plan.return_value = plan
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.result = context.runner.invoke(plan_app, ["status", plan_id])
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@when("I run session show for the session")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_session_show_rich(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Execute ``session show <id>`` (rich output) and store the result."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session_id = context.session_id
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
session = _make_session_with_tokens(session_id=session_id)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.mock_service.get.return_value = session
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
context.result = context.runner.invoke(session_app, ["show", session_id])
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# JSON output assertions
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: The @when step uses wrong CliRunner invoke: runner.invoke(plan_app, status_command, [...]). Extra argument causes TypeError. Fix: invoke(plan_app, ["status", plan_id, "--format", "json"])

BLOCKING: The @when step uses wrong CliRunner invoke: runner.invoke(plan_app, status_command, [...]). Extra argument causes TypeError. Fix: invoke(plan_app, ["status", plan_id, "--format", "json"])
@then('the JSON output contains a "cost" field')
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_json_has_cost_field(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Verify the CLI JSON output includes a ``cost`` key."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.exit_code == 0, (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Expected exit code 0, got {context.result.exit_code}: {context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
parsed = json.loads(context.result.output)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
data = _unwrap_envelope(parsed)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "cost" in data, f"'cost' key not found in JSON: {data}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@then("the cost field contains cost metadata")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_cost_field_has_metadata(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Verify the ``cost`` field includes expected cost metadata keys."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.exit_code == 0, (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Expected exit code 0, got {context.result.exit_code}: {context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
parsed = json.loads(context.result.output)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
data = _unwrap_envelope(parsed)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
cost = data.get("cost", {})
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert isinstance(cost, dict), (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"cost field should be a dict, got {type(cost).__name__}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "total_cost_usd" in cost, "cost field should contain total_cost_usd"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "total_tokens" in cost, "cost field should contain total_tokens"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "input_tokens" in cost, "cost field should contain input_tokens"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "output_tokens" in cost, "cost field should contain output_tokens"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@then('the JSON output contains "estimated_cost" field')
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_json_has_estimated_cost(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Verify JSON output includes ``estimated_cost`` for session."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.exit_code == 0, (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Expected exit code 0, got {context.result.exit_code}: {context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
parsed = json.loads(context.result.output)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
data = _unwrap_envelope(parsed)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "token_usage" in data, f"'token_usage' key not found in JSON: {data}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert "estimated_cost" in data["token_usage"], (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"'estimated_cost' key not found in token_usage: {data['token_usage']}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@then("the estimated_cost is properly formatted as currency")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_estimated_cost_formatted(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Verify ``estimated_cost`` is a currency-formatted string in JSON output."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.exit_code == 0, (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Expected exit code 0, got {context.result.exit_code}: {context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
parsed = json.loads(context.result.output)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
data = _unwrap_envelope(parsed)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
token_usage = data.get("token_usage", {})
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
estimated_cost = token_usage.get("estimated_cost")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert estimated_cost is not None, "estimated_cost should not be None"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert isinstance(estimated_cost, str), (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"estimated_cost should be a string, got {type(estimated_cost).__name__}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert estimated_cost.startswith("$"), (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"estimated_cost should start with '$', got {estimated_cost!r}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: estimated_cost is a formatted string "$0.0080" per spec, but test checks isinstance(estimated_cost, (int, float)). Update assertion to handle string format.

BLOCKING: estimated_cost is a formatted string "$0.0080" per spec, but test checks isinstance(estimated_cost, (int, float)). Update assertion to handle string format.
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# Rich output assertions
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# ---------------------------------------------------------------------------
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@then("the output contains cost information")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_output_has_cost_info(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Verify rich text output contains cost-related keywords."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.exit_code == 0, (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Expected exit code 0, got {context.result.exit_code}: {context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
output_lower = context.result.output.lower()
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
cost_keywords = ["cost", "tokens", "estimated"]
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert any(kw in output_lower for kw in cost_keywords), (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Output should contain cost-related keywords. Output:\n{context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
@then("the cost information is properly formatted")
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
def step_cost_info_formatted(context: Context) -> None:
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
"""Verify cost information follows a reasonable format in rich output."""
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.exit_code == 0, (
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
f"Expected exit code 0, got {context.result.exit_code}: {context.result.output}"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
)
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
# For rich output, validate that the output is non-empty
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
assert context.result.output.strip(), "Rich output should not be empty"
Review

BLOCKING: Missing @when step implementations. All 4 scenarios reference When I run "agents plan status <plan_id>" and When I run "agents session show <session_id>" but no @when decorated functions exist. This is the root cause of the CI unit_tests failure. Add @when functions that parse the command string, execute it (via subprocess or internal service), capture output, and set context.json_output and context.output.

BLOCKING: Missing `@when` step implementations. All 4 scenarios reference `When I run "agents plan status <plan_id>"` and `When I run "agents session show <session_id>"` but no `@when` decorated functions exist. This is the root cause of the CI `unit_tests` failure. Add `@when` functions that parse the command string, execute it (via subprocess or internal service), capture output, and set `context.json_output` and `context.output`.
Review

BLOCKING: All @then steps silently pass via if hasattr(context, "json_output") or if hasattr(context, "output") guards. Since neither variable is ever set by a @when step (none exist anyway), every assertion is a no-op. Remove the hasattr guards and assert unconditionally — the tests should fail loudly if the context data is missing.

BLOCKING: All `@then` steps silently pass via `if hasattr(context, "json_output")` or `if hasattr(context, "output")` guards. Since neither variable is ever set by a `@when` step (none exist anyway), every assertion is a no-op. Remove the `hasattr` guards and assert unconditionally — the tests should fail loudly if the context data is missing.
Review

BLOCKING: @given steps just set arbitrary boolean flags (context.plan_has_cost = True) but do not create real Plan or Session domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with cost_metadata populated.

BLOCKING: `@given` steps just set arbitrary boolean flags (`context.plan_has_cost = True`) but do not create real `Plan` or `Session` domain objects with cost data. The comments say "handled by test fixtures" but no fixture mechanism exists. These steps need to create actual domain model instances with `cost_metadata` populated.
Review

Suggestion: The @then assertions for output-based scenarios are too weak. step_output_has_cost_info matches any text containing the word "cost", "costs", or "tokens". step_cost_info_formatted just checks for $ or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., \$\d+\.\d{2}).

Suggestion: The `@then` assertions for output-based scenarios are too weak. `step_output_has_cost_info` matches any text containing the word "cost", "costs", or "tokens". `step_cost_info_formatted` just checks for `$` or "tokens". Consider checking for specific formatting patterns like dollar amounts with decimal places (e.g., `\$\d+\.\d{2}`).
+2
View File
@@ -306,6 +306,8 @@ def _plan_spec_dict(plan: Any) -> dict[str, object]:
result["last_completed_step"] = plan.last_completed_step
if plan.last_checkpoint_id:
result["last_checkpoint_id"] = plan.last_checkpoint_id
if plan.cost_metadata is not None:
result["cost"] = plan.cost_metadata.as_display_dict()
return result
# Legacy plan fallback