Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Add spec for args passed to module/class_exec. #121

Merged
merged 1 commit into from

1 participant

@headius

No description provided.

@headius headius merged commit 2c36710 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Feb 16, 2012
  1. @headius
This page is out of date. Refresh to see the latest.
Showing with 5 additions and 0 deletions.
  1. +5 −0 core/module/shared/class_exec.rb
View
5 core/module/shared/class_exec.rb
@@ -21,4 +21,9 @@ def foo
it "raises an LocalJumpError when no block is given" do
lambda { ModuleSpecs::Subclass.send(@method) }.should raise_error(LocalJumpError)
end
+
+ it "passes arguments to the block" do
+ a = ModuleSpecs::Subclass
+ a.send(@method, 1) { |b| b }.should equal(1)
+ end
end
Something went wrong with that request. Please try again.