-
Notifications
You must be signed in to change notification settings - Fork 0
feat: add ParseResult JSON schema output #14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,31 @@ | ||||||||||||
| import json | ||||||||||||
|
|
||||||||||||
| from typer.testing import CliRunner | ||||||||||||
|
|
||||||||||||
| from parsemux import __version__ | ||||||||||||
| from parsemux.cli.main import app | ||||||||||||
|
|
||||||||||||
| runner = CliRunner() | ||||||||||||
|
|
||||||||||||
|
|
||||||||||||
| def test_version_command_outputs_version() -> None: | ||||||||||||
| result = runner.invoke(app, ["version"]) | ||||||||||||
|
|
||||||||||||
| assert result.exit_code == 0 | ||||||||||||
| assert result.stdout.strip() == f"parsemux {__version__}" | ||||||||||||
|
|
||||||||||||
|
|
||||||||||||
| def test_version_flag_outputs_version() -> None: | ||||||||||||
| result = runner.invoke(app, ["--version"]) | ||||||||||||
|
|
||||||||||||
| assert result.exit_code == 0 | ||||||||||||
| assert result.stdout.strip() == f"parsemux {__version__}" | ||||||||||||
|
|
||||||||||||
|
|
||||||||||||
|
Comment on lines
+18
to
+24
|
||||||||||||
| def test_version_flag_outputs_version() -> None: | |
| result = runner.invoke(app, ["--version"]) | |
| assert result.exit_code == 0 | |
| assert result.stdout.strip() == f"parsemux {__version__}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
schemacommand docstring says it shows machine-readable schemas for CLI commands, but with--output-schemait outputs the Pydantic JSON Schema forParseResultinstead. Please update the docstring/help text (and the command-schemas payload below, if that’s meant to be complete for agents) to reflect this additional behavior/flag.