For all CLI Unit Test classes we set a property called command_combinations which includes a 2D list of strings which represent the commands we'd like to test. A few of the combinations are stochastic which we should change to something that is repeatable, and other classes' command_combinations are very large and are likely overkill. To address too many tests being ran, we should create a new, small, set of command combinations which we think will hit 100% coverage. If that doesn't occur, we should slowly expand these lists until we reach 100% coverage.
I'm pretty sure this can be done with pytest using the --cov argument. If that doesn't work, we can do a quick search to get the correct result. I'm also pretty sure we can get this to be done automatically using a pytest configuration file.
Background and Motivation
This stems from a bullet point in issue #541.
Code to demonstrate issue
All of the CLI unit tests.
Checklist for Completion
[ ] Grab a small subset of the current command combinations and test them with coverage.
[ ] Expand these lists slowly until 100% coverage is reached.
[ ] Remove stochastic command combinations and replace them with something that is repeatable.
Requested Update
Description
For all CLI Unit Test classes we set a property called
command_combinations
which includes a 2D list of strings which represent the commands we'd like to test. A few of the combinations are stochastic which we should change to something that is repeatable, and other classes'command_combinations
are very large and are likely overkill. To address too many tests being ran, we should create a new, small, set of command combinations which we think will hit 100% coverage. If that doesn't occur, we should slowly expand these lists until we reach 100% coverage.I'm pretty sure this can be done with
pytest
using the--cov
argument. If that doesn't work, we can do a quick search to get the correct result. I'm also pretty sure we can get this to be done automatically using a pytest configuration file.Background and Motivation
This stems from a bullet point in issue #541.
Code to demonstrate issue
All of the CLI unit tests.
Checklist for Completion