Created
December 4, 2009 20:17
-
-
Save brianc/249323 to your computer and use it in GitHub Desktop.
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
require 'rubygems' | |
require 'riot' | |
module Bang | |
def go | |
"yes" | |
end | |
end | |
class Boom | |
def go | |
"no" | |
end | |
end | |
class Boom | |
include Bang | |
end | |
context "Including a module" do | |
should "overwrite normal method" do | |
Boom.new.go | |
end.equals('yes') | |
end | |
# - should overwrite normal method: expected "yes", not "no" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment