forked from btakita/rr
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
require "#{File.dirname(__FILE__)}/spec_helper" | ||
|
||
describe "RR" do | ||
before do | ||
Object.class_eval do | ||
def verify | ||
raise "Dont call me" | ||
end | ||
end | ||
end | ||
|
||
after do | ||
Object.class_eval do | ||
remove_method :verify | ||
end | ||
end | ||
|
||
it "has proxy methods for each method defined directly on Space" do | ||
space_instance_methods = RR::Space.instance_methods(false) | ||
space_instance_methods.should_not be_empty | ||
|
||
rr_instance_methods = RR.methods(false) | ||
space_instance_methods.each do |space_instance_method| | ||
rr_instance_methods.should include(space_instance_method) | ||
end | ||
RR.verify | ||
end | ||
end |