Class: RSpec::Core::Formatters::ProfileFormatter
Class Method Summary
collapse
#dump_profile, #initialize, print_summary
Class Method Details
.most_recent_profile ⇒ Object
44
45
46
47
|
# File 'lib/knapsack_pro/formatters/rspec_queue_profile_formatter_extension.rb', line 44
def self.most_recent_profile
@most_recent_profile ||= {}
@most_recent_profile[ENV['KNAPSACK_PRO_QUEUE_ID']] || []
end
|
.most_recent_profile=(profile) ⇒ Object
38
39
40
41
42
|
# File 'lib/knapsack_pro/formatters/rspec_queue_profile_formatter_extension.rb', line 38
def self.most_recent_profile=(profile)
@most_recent_profile = {
ENV['KNAPSACK_PRO_QUEUE_ID'] => profile
}
end
|
.print_profile_summary ⇒ Object
49
50
51
52
53
54
|
# File 'lib/knapsack_pro/formatters/rspec_queue_profile_formatter_extension.rb', line 49
def self.print_profile_summary
return unless registered_output
profile_formatter = new(registered_output)
profile_formatter.send(:dump_profile_slowest_examples, most_recent_profile)
profile_formatter.send(:dump_profile_slowest_example_groups, most_recent_profile)
end
|
.registered_output ⇒ Object
33
34
35
36
|
# File 'lib/knapsack_pro/formatters/rspec_queue_profile_formatter_extension.rb', line 33
def self.registered_output
@registered_output ||= {}
@registered_output[ENV['KNAPSACK_PRO_QUEUE_ID']]
end
|
.registered_output=(output) ⇒ Object
27
28
29
30
31
|
# File 'lib/knapsack_pro/formatters/rspec_queue_profile_formatter_extension.rb', line 27
def self.registered_output=(output)
@registered_output = {
ENV['KNAPSACK_PRO_QUEUE_ID'] => output
}
end
|