Skip to content
Snippets Groups Projects
Commit 10fa68ae authored by AMOUSSOU Z. Kenneth's avatar AMOUSSOU Z. Kenneth
Browse files

Remove ENV support from rspec-stackprof

Issue: #356084
parent cdcea06e
No related branches found
No related tags found
1 merge request!179436Remove ENV support from rspec-stackprof
......@@ -16,12 +16,12 @@ defaults = {
}
options = {
mode: ENV.fetch('MODE', defaults[:mode]) || defaults[:mode],
interval: ENV['INTERVAL'],
limit: ENV.fetch('LIMIT', nil) || defaults[:limit],
raw: ENV.fetch('RAW', false) === 'true' || defaults[:raw],
output: ENV.fetch('OUTPUT', nil),
speedscope: ENV.fetch('SPEEDSCOPE', false) === 'true' || defaults[:speedscope]
mode: defaults[:mode],
interval: nil,
limit: defaults[:limit],
raw: defaults[:raw],
output: nil,
speedscope: defaults[:speedscope]
}
OptionParser.new do |opt|
......
......@@ -191,7 +191,7 @@ exercises the troublesome code path, then run it using the `bin/rspec-stackprof`
helper, for example:
```shell
$ LIMIT=10 bin/rspec-stackprof spec/policies/project_policy_spec.rb
$ bin/rspec-stackprof --limit=10 spec/policies/project_policy_spec.rb
8/8 |====== 100 ======>| Time: 00:00:18
......@@ -292,7 +292,7 @@ qcachegrind project_policy_spec.callgrind # Mac
```
You can also generate and view the resultant flame graph. To view a flame graph that
`bin/rspec-stackprof` creates, you must set the `RAW` environment variable to `true` when running
`bin/rspec-stackprof` creates, you must add the `--raw=true` option when running
`bin/rspec-stackprof`.
It might take a while to generate based on the output file size:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment