Displaying 1 result from an estimated 1 matches for "inheritedclass".
2007 Jun 11
2
DelegateClass fails
...egating class. Here''s code that demonstrates:
require ''delegate''
gem ''rspec''
# Version 1.0.5
############################################################
# CONTROL EXAMPLE: Works FINE.
############################################################
class InheritedClass < Array
def large?
self.size >= 5
end
end
describe InheritedClass, "normal inheriting class is OK" do
it ''works just fine'' do
myclass = InheritedClass.new([1,2,3,4,5,6])
myclass.should be_large
end
end
########################################...