Sha256: c22cdc916ce49151d9b3b6e5f93cd2ba7761adfb46f33624eaf66f5993360f92

Contents?: true

Size: 491 Bytes

Versions: 59

Compression:

Stored size: 491 Bytes

Contents

rack_api_lib_folder = File.join(File.dirname(__FILE__), '..', 'lib')
$LOAD_PATH.unshift(rack_api_lib_folder)

require "rack/app"
require "rack/mock"
require "benchmark"

class App < Rack::App

  get "/a/b/c/:d/e/f/:g/h/i/j/k/l/m/n/o/p/q/:something" do
    return 'Hello, World!'
  end

end


request = Rack::MockRequest.new(App)

Benchmark.bm do |x|
  x.report do
    request.get("/a/b/c/dog/e/f/goat/h/i/j/k/l/m/n/o/p/q/chicken" )
  end
end

result = Benchmark.measure do

end

puts result

Version data entries

59 entries across 59 versions & 2 rubygems

Version Path
rack-app-6.1.0 spike/long_endpoint.rb
rack-app-6.0.0 spike/long_endpoint.rb
rack-app-5.12.0 spike/long_endpoint.rb
rack-app-5.11.1 spike/long_endpoint.rb
rack-app-5.11.0 spike/long_endpoint.rb
rack-app-5.10.2 spike/long_endpoint.rb
rack-app-5.10.1 spike/long_endpoint.rb
rack-app-5.10.0 spike/long_endpoint.rb
rack-app-5.9.0 spike/long_endpoint.rb
rack-app-5.8.0 spike/long_endpoint.rb
rack-app-5.7.0 spike/long_endpoint.rb
rack-app-5.7.0.rc spike/long_endpoint.rb
rack-app-5.6.0 spike/long_endpoint.rb
rack-app-5.5.1 spike/long_endpoint.rb
rack-app-5.4.0 spike/long_endpoint.rb
rack-app-5.3.2 spike/long_endpoint.rb
rack-app-5.3.1 spike/long_endpoint.rb
rack-app-5.3.0 spike/long_endpoint.rb
rack-app-5.2.0 spike/long_endpoint.rb