Added support for setting the debugger (-u flag)
This commit is contained in:
parent
3dd64624d1
commit
585dc242d6
|
@ -13,7 +13,8 @@ module Guard
|
|||
:start_on_start => true,
|
||||
:force_run => false,
|
||||
:timeout => 20,
|
||||
:server => nil
|
||||
:server => nil,
|
||||
:debugger => nil
|
||||
}
|
||||
|
||||
def initialize(watchers = [], options = {})
|
||||
|
|
|
@ -33,6 +33,7 @@ module Guard
|
|||
rails_options = [
|
||||
'-e', options[:environment],
|
||||
'-p', options[:port],
|
||||
'-u', options[:debugger],
|
||||
'--pid', pid_file
|
||||
]
|
||||
|
||||
|
|
|
@ -46,6 +46,14 @@ describe Guard::RailsRunner do
|
|||
runner.build_rails_command.should match(%r{ -d})
|
||||
end
|
||||
end
|
||||
|
||||
context 'debugger' do
|
||||
let(:options) { default_options.merge(:debugger => true) }
|
||||
|
||||
it "should have a debugger switch" do
|
||||
runner.build_rails_command.should match(%r{ -u})
|
||||
end
|
||||
end
|
||||
|
||||
context 'custom server' do
|
||||
let(:options) { default_options.merge(:server => 'thin') }
|
||||
|
|
Loading…
Reference in New Issue