This happened in a wrapper script, when I'm setting default flags to pass to stack; e.g.
#!/bin/bash
STACK_ARGS=(
--test --no-run-tests
--bench --no-run-benchmarks
)
exec stack "${STACK_ARGS[@]}" "$@"
Steps to reproduce
stack --test --no-run-tests build
stack build --test --no-run-tests
Expected
Either both should build tests and not run them or neither should work (since stack doesn't take those flags on its own)
Actual
The first built and ran tests. The second built but didn't run tests.
In other words, stack --test build and stack --test --no-run-tests build do the same thing.
Stack version
Version 1.6.5, Git revision 24ab0d6ff07f28276e082c3ce74dfdeb1a2ca9e9 (5514 commits) x86_64 hpack-0.20.0
Method of installation
From https://github.com/commercialhaskell/stack/releases/download
This happened in a wrapper script, when I'm setting default flags to pass to stack; e.g.
Steps to reproduce
stack --test --no-run-tests buildstack build --test --no-run-testsExpected
Either both should build tests and not run them or neither should work (since
stackdoesn't take those flags on its own)Actual
The first built and ran tests. The second built but didn't run tests.
In other words,
stack --test buildandstack --test --no-run-tests builddo the same thing.Stack version
Method of installation
From
https://github.com/commercialhaskell/stack/releases/download