Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- commit 88cfcc2eaabe74efeb78a1847dbee1ac20e1d46d
- Author: Ben Brinckerhoff <ben@bbrinck.com>
- Date: Tue Oct 12 22:13:50 2010 -0600
- Added failing spec for class_eval bug
- diff --git a/spec/ruby/core/module/shared/class_eval.rb b/spec/ruby/core/module/shared/class_eval.rb
- index fb9f6a7..e725ff9 100644
- --- a/spec/ruby/core/module/shared/class_eval.rb
- +++ b/spec/ruby/core/module/shared/class_eval.rb
- @@ -31,6 +31,11 @@ describe :module_class_eval, :shared => true do
- ModuleSpecs.send(@method, "[__FILE__, __LINE__]", "test", 102).should == ["test", 102]
- end
- + it "converts a non-string filename to a string using to_str" do
- + (file = mock(__FILE__)).should_receive(:to_str).and_return(__FILE__)
- + ModuleSpecs.send(@method, "1+1", file)
- + end
- +
- it "converts non string eval-string to string using to_str" do
- (o = mock('1 + 1')).should_receive(:to_str).and_return("1 + 1")
- ModuleSpecs.send(@method, o).should == 2
Add Comment
Please, Sign In to add comment