Sha256: fe292e96512ccbd9f0fc585c5f43e86183d5f58ae55f57e3cc4d2db42b04e32c
Contents?: true
Size: 361 Bytes
Versions: 37
Compression:
Stored size: 361 Bytes
Contents
$LOAD_PATH.unshift 'lib' require 'ruco' require 'timeout' require 'tempfile' class Tempfile def self.string_as_file(data) result = nil Tempfile.open('foo') do |f| f.print data f.close result = yield(f.path) end result end end class Time def self.benchmark t = Time.now.to_f yield Time.now.to_f - t end end
Version data entries
37 entries across 37 versions & 1 rubygems