diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2009-05-13 16:15:18 -0700 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2009-05-14 02:01:08 -0700 |
commit | 29bd8f7b8975bc0442f0b63e7da077f9a3f22dc6 (patch) | |
tree | ad2eaec9502f433f540c74928b208e87f250b295 | |
parent | afcbdfc15f919a470e4cfca97fb0084eebd2ab1f (diff) | |
download | rails-29bd8f7b8975bc0442f0b63e7da077f9a3f22dc6.tar.gz rails-29bd8f7b8975bc0442f0b63e7da077f9a3f22dc6.tar.bz2 rails-29bd8f7b8975bc0442f0b63e7da077f9a3f22dc6.zip |
Simple example for require profiling
-rw-r--r-- | actionpack/examples/simple.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/actionpack/examples/simple.rb b/actionpack/examples/simple.rb new file mode 100644 index 0000000000..4ecb824688 --- /dev/null +++ b/actionpack/examples/simple.rb @@ -0,0 +1,17 @@ +$LOAD_PATH.unshift "#{File.dirname(__FILE__)}/../lib" +require 'action_controller' + +class PeopleController < ActionController::Base + def index + head :ok + end +end + +status, headers, body = PeopleController.action(:index).call({ 'rack.input' => StringIO.new('') }) + +puts status +puts headers.to_yaml +puts '---' +body.each do |part| + puts part +end |