create CLI tests around the user's experience #535
Unanswered
johnstonmatt
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am hoping to write some tests for our open source data infrastructure tool CNDI, which is a CLI we built with Deno and Cliffy. Does anyone have a good strategy for programmatically answering interactive prompts we present, to validate outcomes in automated tests?
eg: we have a command
cndi init --interactive
is setup to ask the user for a "project name", and presenting the prompt by invoking the command function is simple enough, but I am unsure how to automatically enter an example project name in thedeno test
environmentThanks for your time!
Beta Was this translation helpful? Give feedback.
All reactions