mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
Fix #1196
This commit is contained in:
parent
4e11c93185
commit
513fc182ca
2 changed files with 7 additions and 1 deletions
|
@ -1,6 +1,6 @@
|
|||
class Pry
|
||||
class Command::Bang < Pry::ClassCommand
|
||||
match '!'
|
||||
match /^\s*!\s*$/
|
||||
group 'Editing'
|
||||
description 'Clear the input buffer.'
|
||||
command_options :use_prefix => false
|
||||
|
|
|
@ -15,4 +15,10 @@ describe "!" do
|
|||
@t.last_output.should =~ /Input buffer cleared!/
|
||||
@t.eval_string.should == ''
|
||||
end
|
||||
|
||||
it 'should not clear the input buffer for negation' do
|
||||
@t.push '! false'
|
||||
@t.last_output.should =~ /true/
|
||||
@t.eval_string.should == ''
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue