Sha256: 250f32dbacac0b7942fd7069690aef1ef86ab080a3dcdb4a4d1e7dab322cac1f

Contents?: true

Size: 215 Bytes

Versions: 21

Compression:

Stored size: 215 Bytes

Contents

module Minitest
  module Let
    def let(name, &block)
      define_method(name) do
        @_memoized ||= {}
        @_memoized.fetch(name) { |k| @_memoized[k] = instance_eval(&block) }
      end
    end
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
gecko-ruby-0.9.1 test/support/let.rb
gecko-ruby-0.9.0 test/support/let.rb
gecko-ruby-0.8.0 test/support/let.rb
gecko-ruby-0.2.6 test/support/let.rb
gecko-ruby-0.7.1 test/support/let.rb
gecko-ruby-0.7.0 test/support/let.rb
gecko-ruby-0.6.0 test/support/let.rb
gecko-ruby-0.5.0 test/support/let.rb
gecko-ruby-0.2.5 test/support/let.rb
gecko-ruby-0.2.4 test/support/let.rb
gecko-ruby-0.2.3 test/support/let.rb
gecko-ruby-0.2.2 test/support/let.rb
gecko-ruby-0.2.0 test/support/let.rb
gecko-ruby-0.1.0 test/support/let.rb
gecko-ruby-0.0.10 test/support/let.rb
gecko-ruby-0.0.9 test/support/let.rb
gecko-ruby-0.0.8 test/support/let.rb
gecko-ruby-0.0.7 test/support/let.rb
gecko-ruby-0.0.6 test/support/let.rb
gecko-ruby-0.0.5 test/support/let.rb