rake icon indicating copy to clipboard operation
rake copied to clipboard

rake no longer deletes processed arguments from ARGV.

Open bretweinraub opened this issue 11 years ago • 3 comments

bretweinraub avatar Dec 17 '14 12:12 bretweinraub

:+1: on 10.4.2.

Trying to test a rake test via cucumber as described here.

When the feature that is testing the rake task is ran in isolation via bundle exec cucumber feature_file.feature, the test passes just fine. However, when leveraging the default task to run all the tests: rake (default task) -> cucumber --profile default ... which leads to a invalid option: --profile (OptionParser::InvalidOption).

So I guess the high level flow of the issues is:

rake (default task) --> cucumber --profile default (cucumber with correct args) --> rake (which incorrectly inherits the parent process args).

Any ideas on a fix?

dleve123 avatar Dec 29 '14 22:12 dleve123

Spent a little time reviewing git history, and I believe that the issue I described above is related, but distinct, from the this issue mentioned by @bretweinraub. Instead of being concerned with rake chipping away at ARGV, I am concerned with rake inheriting options it shouldn't....

dleve123 avatar Dec 29 '14 22:12 dleve123

Has anybody looked at this? I've now noticed this breaking things since 1.0.3.

Option are simply no longer passed through so OptionParser doesn't work in any useful way.

haswalt avatar Feb 18 '15 13:02 haswalt