Is there a way to write command line arguments for tests (exitcode-stdio-1.0) in the cabal file?
I can run the tests manually with
cabal test --test-options="foo bar"
but I don't want to (re-)type this.
There is no way to do this. As the comments suggest, if there are default options for the test-suite, they should just be baked into the executable. Command line options are intended only for overriding or modifying those default options. There is no way to add additional options in the cabal file
来源:https://stackoverflow.com/questions/28902169/put-command-line-arguments-for-tests-in-cabal-file