Skip to content

Commit

Permalink
cabal-testsuite #8401: communicate better that --with-cabal is needed
Browse files Browse the repository at this point in the history
- Add caveat to `--help` text.
- Put `--with-cabal` into very first example in README.
  • Loading branch information
andreasabel committed Jan 13, 2023
1 parent cc8d483 commit beae915
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cabal-testsuite/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ How to run
1. Build `cabal-testsuite` (`cabal build cabal-testsuite:cabal-tests`)
2. Run the `cabal-tests` executable. It will scan for all tests
in your current directory and subdirectories and run them.
To run a specific set of tests, use `cabal-tests PATH ...`.
(e.g. `cabal run cabal-testsuite:cabal-tests -- cabal-testsuite/PackageTests/TestOptions/setup.test.hs`)
To run a specific set of tests, use `cabal-tests --with-cabal=CABALBIN PATH ...`.
(e.g. `cabal run cabal-testsuite:cabal-tests -- --with-cabal=cabal cabal-testsuite/PackageTests/TestOptions/setup.test.hs`)
You can control parallelism using the `-j` flag.

There are a few useful flags:
Expand Down
2 changes: 1 addition & 1 deletion cabal-testsuite/src/Test/Cabal/Monad.hs
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ data CommonArgs = CommonArgs {
commonArgParser :: Parser CommonArgs
commonArgParser = CommonArgs
<$> optional (option str
( help "Path to cabal-install executable to test"
( help "Path to cabal-install executable to test. If omitted, tests involving cabal-install are skipped!"
<> long "with-cabal"
<> metavar "PATH"
))
Expand Down

0 comments on commit beae915

Please sign in to comment.