Ruby Challenge - Method chaining and Lazy Evaluation
问题 After reading the article http://jeffkreeftmeijer.com/2011/method-chaining-and-lazy-evaluation-in-ruby/, I started looking for a better solution for method chaining and lazy evaluation. I think I've encapsulated the core problem with the five specs below; can anyone get them all passing? Anything goes: subclassing, delegation, meta-programming, but discouraged for the latter. It would be favourable to keep dependencies to a minimum: require 'rspec' class Foo # Epic code here end describe Foo