forked from choria-legacy/marionette-collective
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
6354 - MCOLLECTIVE_EXTRA_OPTS not being recognized with unified binary
Pre-parse the MCOLLECTIVE_EXTRA_OPTS stripping out everything except config related options and parse that using the normal optparse environment method
- Loading branch information
Showing
4 changed files
with
76 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#!/usr/bin/env ruby | ||
|
||
require File.dirname(__FILE__) + '/../spec_helper' | ||
|
||
module MCollective | ||
describe Applications do | ||
describe "#filter_extra_options" do | ||
it "should parse --config=x" do | ||
["--config=x --foo=bar -f -f bar", "--foo=bar --config=x -f -f bar"].each do |t| | ||
Applications.filter_extra_options(t).should == "--config=x" | ||
end | ||
end | ||
|
||
it "should parse --config x" do | ||
["--config x --foo=bar -f -f bar", "--foo=bar --config x -f -f bar"].each do |t| | ||
Applications.filter_extra_options(t).should == "--config=x" | ||
end | ||
end | ||
|
||
it "should parse -c x" do | ||
["-c x --foo=bar -f -f bar", "--foo=bar -c x -f -f bar"].each do |t| | ||
Applications.filter_extra_options(t).should == "--config=x" | ||
end | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters