Commit cf0b2dc7 authored by Roy Zwambag's avatar Roy Zwambag

Require 'rspec' to fix bin/rspec-stackprof

parent c4a9ac20
...@@ -2,13 +2,12 @@ ...@@ -2,13 +2,12 @@
require_relative '../config/bundler_setup' require_relative '../config/bundler_setup'
require 'stackprof' require 'stackprof'
$:.unshift 'spec' require 'rspec'
require 'spec_helper'
filename = ARGV[0].split('/').last filename = ARGV[0].split('/').last
interval = ENV.fetch('INTERVAL', 1000).to_i interval = ENV.fetch('INTERVAL', 1000).to_i
limit = ENV.fetch('LIMIT', 20) limit = ENV.fetch('LIMIT', 20)
raw = ENV.fetch('RAW', false) == 'true' raw = ENV.fetch('RAW', false) == 'true' # Set this to true if you want to generate a flamegraph
output_file = "tmp/#{filename}.dump" output_file = "tmp/#{filename}.dump"
StackProf.run(mode: :wall, out: output_file, interval: interval, raw: raw) do StackProf.run(mode: :wall, out: output_file, interval: interval, raw: raw) do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment