Created
February 12, 2015 19:25
-
-
Save jhawthorn/215c8bd29de44f2a7be1 to your computer and use it in GitHub Desktop.
Throw this in spec/support and run specs as normal. Stackprof will output a profile to the tmp directory.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Capybara.app = Rack::Builder.new do | |
map "/" do | |
use StackProf::Middleware, | |
enabled: true, | |
mode: :wall, | |
interval: 100, | |
save_at_exit: true | |
run Rails.application | |
end | |
end.to_app |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment