mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
rewrite test on top of ReplTester
.
This commit is contained in:
parent
d9ce4b5436
commit
7306fdee3a
1 changed files with 4 additions and 5 deletions
|
@ -135,12 +135,11 @@ describe "show-source" do
|
|||
Object.remove_const(:FooBar)
|
||||
end
|
||||
|
||||
it "should find methods of evaluated argument" do
|
||||
def @o.foobar
|
||||
FooBar.new
|
||||
it "evaluates the argument as ruby and shows the source code for the returned value" do
|
||||
ReplTester.start target: binding do
|
||||
input 'show-source -e @o.foobar'
|
||||
output /class FooBar/
|
||||
end
|
||||
|
||||
pry_eval(binding, 'show-source -e @o.foobar').should =~ /class FooBar/
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue