Test lotus CLI output
masih opened this issue · 0 comments
masih commented
There is currently barely any testing for CLI output, or a stablished way by which one would write tests for new CLIs in Louts. Such tests can be written using the existing integration test kit, where cli
package level functions that return full node APIs can be swapped with a test kit node for testing to then proceed by instantiating a new urfav cli.App
with the target command, etc. etc.
Ideally we should:
- have a CLI test kit, a thin wrapper around current kit with some utilities for CLI testing
- establish testdata pattern (for expected output given a command) to be able to easily add new tests.