Skip to content

cli: Add tests for tns help #326

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

Open
rosen-vladimirov opened this issue Aug 19, 2019 · 0 comments
Open

cli: Add tests for tns help #326

rosen-vladimirov opened this issue Aug 19, 2019 · 0 comments

Comments

@rosen-vladimirov
Copy link
Contributor

rosen-vladimirov commented Aug 19, 2019

Add tests to verify CLI shows its help properly:

  • tns -h should print the help
  • tns --help should print the help
  • tns <command> --help should print command's help
  • Add test to verify tns dev-generate-help is working - this command should generate all the .html files of the help and it is used for our documentation. The generation of help can be broken by either changes in the code or changes in any help page. As CLI supports injecting code in the help pages, when the help is generated, in case the code in the help page is invalid, generation of html files will fail. So it is important to have a test that does the following:
    • remove <cli installation dir>/docs/html
    • execute tns dev-generate-help
    • ensure the exit code of the above mentioned command is 0.
    • ensures there are files in <cli installation dir>/docs/html.
  • tns help should open browser (I know it is not easy to be tested, so this can be added in the future. For the moment we can just ensure CLI is not printing its command line help in this case.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant