Closed nkrabben closed 1 year ago
My preference would be to test
main()
against the following cases.
- Not enough processes
- Invalid use of
--fast
- Invalid use of
--completeness-only
- Successful validate
--fast
- Successful validate
--completeness-only
- Successful validate
- Unsuccessful validate
--fast
- Unsuccessful validate
--completeness-only
- Unsuccessful validate
- Successful bag creation
- Unsuccessful bag creation
That sound like a good and thorough approach to me :+1:
A couple years ago I wanted to add CLI tests.
I've since tried a couple strategies on other projects, none of which are clearly preferably. The two strategies I'm consider are:
_make_parser()
which is relatively straightforward but leavesmain()
untested, where bugs are more likely to occur.main()
which is more complete but repeats many of the existing tests, just with an additional abstraction layer.My preference would be to test
main()
against the following cases.--fast
--completeness-only
--fast
--completeness-only
--fast
--completeness-only
Does that sound like a good strategy? I'm happy to go in another direction.