Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v2-test in master should ignore --test-option[s] from the hash #5789

Open
fommil opened this issue Dec 11, 2018 · 3 comments
Open

v2-test in master should ignore --test-option[s] from the hash #5789

fommil opened this issue Dec 11, 2018 · 3 comments

Comments

@fommil
Copy link
Contributor

fommil commented Dec 11, 2018

in any project with tasty, with cabal 2.5, running this

cabal v2-test -O0 --test-options="--pattern Foo"

followed by

cabal v2-test -O0 --test-options="--pattern Bar"

will result in trying to recompile everything.

It looks like test-option and test-options are being included in the hash.

@anka-213
Copy link

anka-213 commented Apr 8, 2021

Does anyone know of a workaround for this problem? It's getting pretty frustrating.

@fommil
Copy link
Contributor Author

fommil commented Apr 8, 2021

I invoke test binaries directly with run and just pretend test doesn't exist.

cabal run tasty -- --pattern Foo
cabal run tasty -- --pattern Bar

doesn't recompile

@anka-213
Copy link

anka-213 commented Apr 8, 2021

@fommil That almost works, but now the test-suite fails to execute the main executable ghcide and other tools which are included via build-tool-depends:

test-suite ghcide-tests
    build-tool-depends:
        ghcide:ghcide,
        ghcide:ghcide-test-preprocessor,
        implicit-hie:gen-hie
    ...
$ cabal run ghcide-tests
Up to date
cabal get -v1 Cabal-3.2.0.0 -d bench/example
ghcide
  diagnostics
    haddock parse error:          FAIL
      Exception: ghcide: createProcess: runInteractiveProcess: exec: does not exist (No such file or directory)
...
    hover after edit:             FAIL
      Exception: gen-hie: createProcess: runInteractiveProcess: exec: does not exist (No such file or directory)

Is there some alternative runtime-tool-depends or another way to make this work?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants