Refactor public API around environments
This commit is contained in:
parent
57dae52cc2
commit
5d5243df23
41 changed files with 1301 additions and 459 deletions
|
|
@ -15,6 +15,7 @@ from pyro_mcp.cli import _build_parser
|
|||
from pyro_mcp.contract import (
|
||||
PUBLIC_CLI_COMMANDS,
|
||||
PUBLIC_CLI_DEMO_SUBCOMMANDS,
|
||||
PUBLIC_CLI_ENV_SUBCOMMANDS,
|
||||
PUBLIC_CLI_RUN_FLAGS,
|
||||
PUBLIC_MCP_TOOLS,
|
||||
PUBLIC_SDK_METHODS,
|
||||
|
|
@ -49,14 +50,19 @@ def test_public_cli_help_lists_commands_and_run_flags() -> None:
|
|||
|
||||
run_parser = _build_parser()
|
||||
run_help = run_parser.parse_args(
|
||||
["run", "--profile", "debian-base", "--vcpu-count", "1", "--mem-mib", "512", "--", "true"]
|
||||
["run", "debian:12-base", "--vcpu-count", "1", "--mem-mib", "512", "--", "true"]
|
||||
)
|
||||
assert run_help.command == "run"
|
||||
assert run_help.environment == "debian:12-base"
|
||||
|
||||
run_help_text = _subparser_choice(parser, "run").format_help()
|
||||
for flag in PUBLIC_CLI_RUN_FLAGS:
|
||||
assert flag in run_help_text
|
||||
|
||||
env_help_text = _subparser_choice(parser, "env").format_help()
|
||||
for subcommand_name in PUBLIC_CLI_ENV_SUBCOMMANDS:
|
||||
assert subcommand_name in env_help_text
|
||||
|
||||
demo_help_text = _subparser_choice(parser, "demo").format_help()
|
||||
for subcommand_name in PUBLIC_CLI_DEMO_SUBCOMMANDS:
|
||||
assert subcommand_name in demo_help_text
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue