Follow-up to #724: the argument parsers are tested now, but cli.rkt is still at 68.6% coverage (114 missed lines) because none of the run functions are. Untested: the resyntax-run command dispatch, all of resyntax-analyze-run including the plain-text display and --output-to-file, and the fix output printers (--output-as-commit-message, --output-as-json, and most of the plain-text summary).
The existing "resyntax fix modifies files" test shows the pattern to follow: parameterize current-command-line-arguments and current-output-port, run against a temp file, and assert on the captured output. An analyze equivalent would also transitively cover the untested code snippet accessors in refactoring-result.rkt (#815) and several untested limiting branches in main.rkt.
Part of #680.
Follow-up to #724: the argument parsers are tested now, but
cli.rktis still at 68.6% coverage (114 missed lines) because none of the run functions are. Untested: theresyntax-runcommand dispatch, all ofresyntax-analyze-runincluding the plain-text display and--output-to-file, and the fix output printers (--output-as-commit-message,--output-as-json, and most of the plain-text summary).The existing "resyntax fix modifies files" test shows the pattern to follow: parameterize
current-command-line-argumentsandcurrent-output-port, run against a temp file, and assert on the captured output. An analyze equivalent would also transitively cover the untested code snippet accessors inrefactoring-result.rkt(#815) and several untested limiting branches inmain.rkt.Part of #680.