Add tests for container subcommand argument validation #19
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
title: Add tests for container subcommand argument validation
description: Ensure regression coverage for the repeated "Index out of bounds" errors when container subcommands lack required arguments (e.g.,
container pull,container save).current_situation:
DocMachine::Container::Clishifts arguments without checks (src/container/cli.cr:53-80). Multiple user reports (pull,save) show the CLI crashing with the same stack trace. Task [5d8410b] will implement validation, but no automated tests exist to prevent future regressions.expected_outcome:
docmachine containersubcommands with missing args (pull/run/save/load) and asserts that friendlyDocMachine::CliErrors are raised and usage/help text is displayed.args.shiftcalls without guards.technical_details:
spec/container/cli_spec.cror new integration harness) executing the CLI entrypoints.Process.run("crystal", ["run", ...])or refactor CLI to allow invokingDocMachine::Cli#startdirectly from tests with argument arrays.fcd4b67 Add tests for container subcommand argument validationto Add tests for container subcommand argument validation