072d5404ee
--- It seems like the new interactor eats input from $stdin even while it is locked. This disallow using tools like ruby-debug or pry in specs or cucumber. The fix just kills the interactor when it is locked and runs it again when ulocked. Conflicts: lib/guard/interactor.rb
29 lines
517 B
Ruby
29 lines
517 B
Ruby
require 'spec_helper'
|
|
|
|
describe Guard::Interactor do
|
|
subject { Guard::Interactor.new }
|
|
|
|
describe "#initialize" do
|
|
it "unlocks the interactor by default" do
|
|
subject.locked.should be_false
|
|
end
|
|
end
|
|
|
|
describe "#lock" do
|
|
it "locks the interactor" do
|
|
subject.start
|
|
subject.lock
|
|
subject.locked.should be_true
|
|
end
|
|
end
|
|
|
|
describe "#unlock" do
|
|
it "unlocks the interactor" do
|
|
subject.start
|
|
subject.unlock
|
|
subject.locked.should be_false
|
|
end
|
|
end
|
|
|
|
end
|