1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

Don't "puts" during tests

This commit is contained in:
Conrad Irwin 2011-09-12 00:59:51 -07:00
parent 7f9adcb40c
commit 82ac5585c4

View file

@ -570,14 +570,14 @@ describe Pry do
it 'should NOT try to interpolate pure ruby code (no commands) ' do
str_output = StringIO.new
Pry.new(:input => StringIO.new('puts \'#{aggy}\''), :output => str_output).rep
Pry.new(:input => StringIO.new('format \'#{aggy}\''), :output => str_output).rep
str_output.string.should.not =~ /NameError/
Pry.new(:input => StringIO.new('puts #{aggy}'), :output => str_output).rep
Pry.new(:input => StringIO.new('format #{aggy}'), :output => str_output).rep
str_output.string.should.not =~ /NameError/
$test_interpolation = "blah"
Pry.new(:input => StringIO.new('puts \'#{$test_interpolation}\''), :output => str_output).rep
Pry.new(:input => StringIO.new('format \'#{$test_interpolation}\''), :output => str_output).rep
str_output.string.should.not =~ /blah/
$test_interpolation = nil