Skip to content

test(cli): cover adk conformance test command options - #6874

Closed
rootkiller6788 wants to merge 1 commit into
google:mainfrom
rootkiller6788:test-cli-conformance-options
Closed

rootkiller6788 wants to merge 1 commit into
google:mainfrom
rootkiller6788:test-cli-conformance-options

Conversation

@rootkiller6788

Copy link
Copy Markdown
Contributor

What

Adds focused unit tests for the adk conformance test CLI command (requested in #6730). The command dispatches to run_conformance_test; the existing tests in this module already cover the no-path default, single-directory, --mode replay, --generate_report, --report_dir, and --streaming-mode sse cases. This change closes the remaining gaps:

  • Multiple PATHS are all forwarded to the runner.
  • --mode live is propagated as "live".
  • --streaming-mode bidi is parsed to StreamingMode.BIDI.
  • An invalid --mode value is rejected by Click (exit code 2) before any dispatch.
  • An invalid --streaming-mode value is rejected by Click (exit code 2) before any dispatch.

The conformance runner is mocked (same pattern as the surrounding tests) so the suite stays fast and deterministic with no real LLM execution.

Why

These CLI behaviors had no automated coverage, leaving regressions in argument handling unguarded.

Testing

$ python -m pytest tests/unittests/cli/utils/test_cli_tools_click.py -k conformance -q
11 passed, 92 deselected

(5 new tests on top of the pre-existing conformance tests.) pyink --check and ruff check are clean on the changed file.

Add focused unit tests for the argument handling of `adk conformance test`
(issue google#6730): multiple PATHS are all forwarded, --mode live is propagated,
--streaming-mode bidi maps to the StreamingMode enum, and invalid --mode /
--streaming-mode values are rejected by Click before any dispatch.

The runner is mocked so the tests stay fast and deterministic, matching the
existing conformance CLI tests in this module.
copybara-service Bot pushed a commit that referenced this pull request Aug 26, 2026
@adk-bot

adk-bot commented Aug 26, 2026

Copy link
Copy Markdown
Collaborator

Thank you @rootkiller6788 for your contribution! 🎉

Your changes have been successfully imported and merged via Copybara in commit 7d9f2d0.

Closing this PR as the changes are now in the main branch.

@adk-bot adk-bot added the merged [Status] This PR is merged label Aug 26, 2026
@adk-bot adk-bot closed this Aug 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged [Status] This PR is merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants