mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
Fix warnings
This commit is contained in:
parent
07fd525886
commit
5fd4074ae7
2 changed files with 4 additions and 4 deletions
|
@ -18,7 +18,7 @@ class Pry
|
||||||
end
|
end
|
||||||
|
|
||||||
def text(str, width = str.length)
|
def text(str, width = str.length)
|
||||||
super *if !Pry.color
|
super(*if !Pry.color
|
||||||
[str, width]
|
[str, width]
|
||||||
# Don't recolorize output with color [Issue #751]
|
# Don't recolorize output with color [Issue #751]
|
||||||
elsif str.include?("\e[")
|
elsif str.include?("\e[")
|
||||||
|
@ -27,7 +27,7 @@ class Pry
|
||||||
[highlight_object_literal(str), width]
|
[highlight_object_literal(str), width]
|
||||||
else
|
else
|
||||||
[CodeRay.scan(str, :ruby).term, width]
|
[CodeRay.scan(str, :ruby).term, width]
|
||||||
end
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
def pp(obj)
|
def pp(obj)
|
||||||
|
|
|
@ -48,8 +48,8 @@ describe Pry::Hooks do
|
||||||
end
|
end
|
||||||
end.parse_options(["--optiontest", "--optiontest2"])
|
end.parse_options(["--optiontest", "--optiontest2"])
|
||||||
|
|
||||||
run.should == true
|
run.should.be.true
|
||||||
run2.should == true
|
run2.should.be.true
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue