class MiniTest::Spec
def self.bench name, &block
def self.bench name, &block define_method "bench_#{name.gsub(/\W+/, '_')}", &block end
def self.bench_performance_constant name, threshold = 0.99, &work
def self.bench_performance_constant name, threshold = 0.99, &work bench name do assert_performance_constant threshold, &work end end
def self.bench_performance_exponential name, threshold = 0.99, &work
def self.bench_performance_exponential name, threshold = 0.99, &work bench name do assert_performance_exponential threshold, &work end end
def self.bench_performance_linear name, threshold = 0.99, &work
def self.bench_performance_linear name, threshold = 0.99, &work bench name do assert_performance_linear threshold, &work end end
def self.bench_range &block
def self.bench_range &block return super unless block meta = (class << self; self; end) meta.send :define_method, "bench_range", &block end