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

Can't specify --test-arguments more than once #2226

Closed
cblp opened this issue Jun 1, 2016 · 4 comments

Comments

Projects
None yet
3 participants
@cblp
Copy link
Contributor

commented Jun 1, 2016

$ stack test --test-arguments "a b" --test-arguments "c d"
Invalid option `--test-arguments'

stack=1.1.2

expected: testArguments == ["a", "b", "c", "d"]

@mgsloan

This comment has been minimized.

Copy link
Collaborator

commented Jun 1, 2016

I'm not opposed to this, but what's the intended usecase? I can also see value in the reset semantics and this would be a behavior change.

We'd also need to revisit other similar flags and change their behavior for consistency with this one. For example, the flags for invoked programs - #652

@cblp

This comment has been minimized.

Copy link
Contributor Author

commented Jun 2, 2016

Intended usecase:

  1. Write a script with persistent arguments

    # ./test.sh
    stack test --test-arguments="--report --verbose" "$@"
    
  2. Invoke it with ad hoc arguments

    ./test.sh --test-arguments="--parallel --filter=abc"
    
@mgsloan

This comment has been minimized.

Copy link
Collaborator

commented Jun 2, 2016

Makes sense! I think the resolution of this ticket should be that all command-argument like options have this combining semantics.

@snoyberg

This comment has been minimized.

Copy link
Contributor

commented Apr 16, 2019

See #4748

@snoyberg snoyberg closed this in 45ded48 Apr 16, 2019

snoyberg added a commit that referenced this issue Apr 16, 2019

Merge pull request #4748 from commercialhaskell/2226-multiple-test-ar…
…guments

Allow multiple --test-arguments to be passed (fixes #2226)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.