describe keeps a remark with its option and allows a bare call

animation.remove's remark belongs to its `ids` option, so describe shows
it there instead of as a note on the whole command. A command with an
all-optional set of parameters is suggested as a bare id.

[claude-opus-5-5] on behalf of hoblin
This commit is contained in:
Yevhenii Hurin
2026-10-13 09:55:19 +03:00
parent 426fd71bd2
commit 922445300b
3 changed files with 6 additions and 2 deletions
+3
View File
@@ -115,6 +115,9 @@ Run it with: deckcraft-cli run --cmd 'format.size={…}'
#[test]
fn describe_shows_alternative_sets_of_parameters() {
assert!(stdout(&cli(&["describe", "slide.go"])).contains("Parameters:\n either:\n index\n or:\n id\n"));
let remove = stdout(&cli(&["describe", "animation.remove"]));
assert!(remove.contains(" or:\n ids, optional (all of the shapes' animations)\n"), "{remove}");
assert!(remove.ends_with("Run it with: deckcraft-cli run --cmd animation.remove\n") && !remove.contains("Note:"), "{remove}");
assert!(stdout(&cli(&["describe", "shape.move"])).contains(
" either:
dx, optional pt (relative)