Created
June 13, 2010 13:06
-
-
Save gcao/436642 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
before :test do | |
puts 'before 1' | |
end | |
around :test do |proxy| | |
puts 'around(before)' | |
result = a4r_invoke proxy | |
puts 'around(after)' | |
result | |
end | |
before :test do | |
puts 'before 2' | |
end | |
def test | |
puts 'test' | |
end | |
instance.test | |
# === Output === | |
# before 2 | |
# around(before) | |
# before 1 | |
# test | |
# around(after) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment