Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 23 lines (20 sloc) 0.3 kb
56eaab2 Mike Pack Initial commit
authored
1 require 'benchmark'
2 require './runner'
3
4 class IncludeUser
5 include Runner
6 end
7
2380a02 Mike Pack Add refinement benchmark
authored
8 class Context
bf05983 Mike Pack Use #call
authored
9 def self.call
2380a02 Mike Pack Add refinement benchmark
authored
10 user = IncludeUser.new
11 user.run
12 end
13 end
14
56eaab2 Mike Pack Initial commit
authored
15 Benchmark.bm do |bench|
16 3.times do
17 bench.report('include') do
18 1000000.times do
bf05983 Mike Pack Use #call
authored
19 Context.call
56eaab2 Mike Pack Initial commit
authored
20 end
21 end
22 end
23 end
Something went wrong with that request. Please try again.