metric_fu 2.1.3.7.19 → 2.1.4.pre

Sign up to get free protection for your applications and to get access to all the features.
Files changed (142) hide show
  1. data/.rspec +2 -0
  2. data/.travis.yml +12 -0
  3. data/Gemfile +2 -2
  4. data/HISTORY.md +15 -2
  5. data/README.md +19 -12
  6. data/TODO.md +121 -7
  7. data/bin/metric_fu +134 -2
  8. data/lib/metric_fu.rb +8 -1
  9. data/lib/metric_fu/configuration.rb +192 -0
  10. data/lib/{data_structures → metric_fu/data_structures}/careful_array.rb +0 -0
  11. data/lib/{data_structures → metric_fu/data_structures}/line_numbers.rb +0 -0
  12. data/lib/{data_structures → metric_fu/data_structures}/location.rb +0 -0
  13. data/lib/{errors → metric_fu/errors}/analysis_error.rb +0 -0
  14. data/lib/{initial_requires.rb → metric_fu/initial_requires.rb} +1 -0
  15. data/lib/{load_files.rb → metric_fu/load_files.rb} +0 -8
  16. data/lib/{logging → metric_fu/logging}/mf_debugger.rb +0 -0
  17. data/lib/{metrics → metric_fu/metrics}/base_template.rb +0 -0
  18. data/lib/metric_fu/metrics/churn/churn.rb +64 -0
  19. data/lib/{metrics → metric_fu/metrics}/churn/churn_hotspot.rb +0 -0
  20. data/lib/metric_fu/metrics/churn/init.rb +5 -0
  21. data/lib/{metrics → metric_fu/metrics}/churn/template_awesome/churn.html.erb +0 -0
  22. data/lib/{metrics → metric_fu/metrics}/churn/template_standard/churn.html.erb +0 -0
  23. data/lib/{metrics → metric_fu/metrics}/flay/flay.rb +3 -1
  24. data/lib/{metrics → metric_fu/metrics}/flay/flay_grapher.rb +0 -0
  25. data/lib/{metrics → metric_fu/metrics}/flay/flay_hotspot.rb +0 -0
  26. data/lib/metric_fu/metrics/flay/init.rb +9 -0
  27. data/lib/{metrics → metric_fu/metrics}/flay/template_awesome/flay.html.erb +0 -0
  28. data/lib/{metrics → metric_fu/metrics}/flay/template_standard/flay.html.erb +0 -0
  29. data/lib/{metrics → metric_fu/metrics}/flog/flog.rb +0 -0
  30. data/lib/{metrics → metric_fu/metrics}/flog/flog_grapher.rb +0 -0
  31. data/lib/{metrics → metric_fu/metrics}/flog/flog_hotspot.rb +0 -0
  32. data/lib/metric_fu/metrics/flog/init.rb +7 -0
  33. data/lib/{metrics → metric_fu/metrics}/flog/template_awesome/flog.html.erb +0 -0
  34. data/lib/{metrics → metric_fu/metrics}/flog/template_standard/flog.html.erb +0 -0
  35. data/lib/{metrics → metric_fu/metrics}/generator.rb +3 -4
  36. data/lib/{metrics → metric_fu/metrics}/graph.rb +0 -0
  37. data/lib/{metrics → metric_fu/metrics}/hotspots/analysis/code_issue.rb +0 -0
  38. data/lib/{metrics → metric_fu/metrics}/hotspots/analysis/grouping.rb +0 -0
  39. data/lib/{metrics → metric_fu/metrics}/hotspots/analysis/ranking.rb +0 -0
  40. data/lib/{metrics → metric_fu/metrics}/hotspots/analysis/record.rb +0 -0
  41. data/lib/{metrics → metric_fu/metrics}/hotspots/analysis/scoring_strategies.rb +0 -0
  42. data/lib/{metrics → metric_fu/metrics}/hotspots/analysis/table.rb +0 -0
  43. data/lib/{metrics → metric_fu/metrics}/hotspots/hotspot_analyzer.rb +0 -0
  44. data/lib/{metrics → metric_fu/metrics}/hotspots/hotspots.rb +0 -0
  45. data/lib/metric_fu/metrics/hotspots/init.rb +5 -0
  46. data/lib/{metrics → metric_fu/metrics}/hotspots/template_awesome/hotspots.html.erb +0 -0
  47. data/lib/{metrics → metric_fu/metrics}/hotspots/template_standard/hotspots.html.erb +0 -0
  48. data/lib/metric_fu/metrics/rails_best_practices/init.rb +7 -0
  49. data/lib/{metrics → metric_fu/metrics}/rails_best_practices/rails_best_practices.rb +4 -2
  50. data/lib/{metrics → metric_fu/metrics}/rails_best_practices/rails_best_practices_grapher.rb +0 -0
  51. data/lib/{metrics → metric_fu/metrics}/rails_best_practices/template_awesome/rails_best_practices.html.erb +0 -0
  52. data/lib/{metrics → metric_fu/metrics}/rails_best_practices/template_standard/rails_best_practices.html.erb +0 -0
  53. data/lib/metric_fu/metrics/rcov/init.rb +18 -0
  54. data/lib/{metrics → metric_fu/metrics}/rcov/rcov.rb +22 -7
  55. data/lib/{metrics → metric_fu/metrics}/rcov/rcov_grapher.rb +0 -0
  56. data/lib/{metrics → metric_fu/metrics}/rcov/rcov_hotspot.rb +0 -0
  57. data/lib/{metrics → metric_fu/metrics}/rcov/template_awesome/rcov.html.erb +0 -0
  58. data/lib/{metrics → metric_fu/metrics}/rcov/template_standard/rcov.html.erb +0 -0
  59. data/lib/metric_fu/metrics/reek/init.rb +7 -0
  60. data/lib/{metrics → metric_fu/metrics}/reek/reek.rb +3 -1
  61. data/lib/{metrics → metric_fu/metrics}/reek/reek_grapher.rb +0 -0
  62. data/lib/{metrics → metric_fu/metrics}/reek/reek_hotspot.rb +0 -0
  63. data/lib/{metrics → metric_fu/metrics}/reek/template_awesome/reek.html.erb +0 -0
  64. data/lib/{metrics → metric_fu/metrics}/reek/template_standard/reek.html.erb +0 -0
  65. data/lib/metric_fu/metrics/roodi/init.rb +7 -0
  66. data/lib/{metrics → metric_fu/metrics}/roodi/roodi.rb +3 -1
  67. data/lib/{metrics → metric_fu/metrics}/roodi/roodi_grapher.rb +0 -0
  68. data/lib/{metrics → metric_fu/metrics}/roodi/roodi_hotspot.rb +0 -0
  69. data/lib/{metrics → metric_fu/metrics}/roodi/template_awesome/roodi.html.erb +0 -0
  70. data/lib/{metrics → metric_fu/metrics}/roodi/template_standard/roodi.html.erb +0 -0
  71. data/lib/metric_fu/metrics/saikuro/init.rb +11 -0
  72. data/lib/{metrics → metric_fu/metrics}/saikuro/saikuro.rb +0 -0
  73. data/lib/{metrics → metric_fu/metrics}/saikuro/saikuro_hotspot.rb +0 -0
  74. data/lib/{metrics → metric_fu/metrics}/saikuro/template_awesome/saikuro.html.erb +0 -0
  75. data/lib/{metrics → metric_fu/metrics}/saikuro/template_standard/saikuro.html.erb +0 -0
  76. data/lib/metric_fu/metrics/stats/init.rb +7 -0
  77. data/lib/{metrics → metric_fu/metrics}/stats/stats.rb +3 -1
  78. data/lib/{metrics → metric_fu/metrics}/stats/stats_grapher.rb +0 -0
  79. data/lib/{metrics → metric_fu/metrics}/stats/stats_hotspot.rb +0 -0
  80. data/lib/{metrics → metric_fu/metrics}/stats/template_awesome/stats.html.erb +0 -0
  81. data/lib/{metrics → metric_fu/metrics}/stats/template_standard/stats.html.erb +0 -0
  82. data/lib/{reporting → metric_fu/reporting}/graphs/engines/bluff.rb +0 -0
  83. data/lib/{reporting → metric_fu/reporting}/graphs/engines/gchart.rb +0 -0
  84. data/lib/metric_fu/reporting/graphs/engines/init.rb +5 -0
  85. data/lib/{reporting → metric_fu/reporting}/graphs/grapher.rb +0 -0
  86. data/lib/{reporting → metric_fu/reporting}/report.rb +3 -2
  87. data/lib/{reporting → metric_fu/reporting}/templates/awesome/awesome_template.rb +0 -0
  88. data/lib/{reporting → metric_fu/reporting}/templates/awesome/css/buttons.css +0 -0
  89. data/lib/{reporting → metric_fu/reporting}/templates/awesome/css/default.css +0 -0
  90. data/lib/{reporting → metric_fu/reporting}/templates/awesome/css/integrity.css +0 -0
  91. data/lib/{reporting → metric_fu/reporting}/templates/awesome/css/reset.css +0 -0
  92. data/lib/{reporting → metric_fu/reporting}/templates/awesome/css/syntax.css +0 -0
  93. data/lib/{reporting → metric_fu/reporting}/templates/awesome/index.html.erb +0 -0
  94. data/lib/{reporting → metric_fu/reporting}/templates/awesome/layout.html.erb +0 -0
  95. data/lib/{reporting → metric_fu/reporting}/templates/javascripts/bluff-min.js +0 -0
  96. data/lib/{reporting → metric_fu/reporting}/templates/javascripts/excanvas.js +0 -0
  97. data/lib/{reporting → metric_fu/reporting}/templates/javascripts/js-class.js +0 -0
  98. data/lib/{reporting → metric_fu/reporting}/templates/standard/default.css +0 -0
  99. data/lib/{reporting → metric_fu/reporting}/templates/standard/index.html.erb +0 -0
  100. data/lib/{reporting → metric_fu/reporting}/templates/standard/standard_template.rb +0 -0
  101. data/lib/{run.rb → metric_fu/run.rb} +12 -11
  102. data/lib/{tasks → metric_fu/tasks}/metric_fu.rake +0 -0
  103. data/lib/metric_fu/version.rb +3 -0
  104. data/metric_fu.gemspec +13 -21
  105. data/spec/metric_fu/configuration_spec.rb +298 -0
  106. data/spec/{base → metric_fu/data_structures}/line_numbers_spec.rb +11 -11
  107. data/spec/{base → metric_fu/data_structures}/location_spec.rb +1 -1
  108. data/spec/{base → metric_fu/metrics}/base_template_spec.rb +1 -1
  109. data/spec/metric_fu/metrics/churn/churn_spec.rb +85 -0
  110. data/spec/{graphs → metric_fu/metrics/flay}/flay_grapher_spec.rb +3 -3
  111. data/spec/{generators → metric_fu/metrics/flay}/flay_spec.rb +1 -1
  112. data/spec/{graphs → metric_fu/metrics/flog}/flog_grapher_spec.rb +4 -4
  113. data/spec/{generators → metric_fu/metrics/flog}/flog_spec.rb +1 -1
  114. data/spec/{base → metric_fu/metrics}/generator_spec.rb +4 -3
  115. data/spec/{base → metric_fu/metrics}/graph_spec.rb +1 -1
  116. data/spec/{base → metric_fu/metrics/hotspots/analysis}/ranking_spec.rb +1 -1
  117. data/spec/{base → metric_fu/metrics/hotspots/analysis}/table_spec.rb +1 -1
  118. data/spec/{base → metric_fu/metrics/hotspots}/hotspot_analyzer_spec.rb +1 -1
  119. data/spec/{generators → metric_fu/metrics/hotspots}/hotspots_spec.rb +1 -1
  120. data/spec/{graphs → metric_fu/metrics/rails_best_practices}/rails_best_practices_grapher_spec.rb +3 -3
  121. data/spec/{generators → metric_fu/metrics/rails_best_practices}/rails_best_practices_spec.rb +1 -1
  122. data/spec/{graphs → metric_fu/metrics/rcov}/rcov_grapher_spec.rb +3 -3
  123. data/spec/{generators → metric_fu/metrics/rcov}/rcov_spec.rb +1 -1
  124. data/spec/{graphs → metric_fu/metrics/reek}/reek_grapher_spec.rb +3 -3
  125. data/spec/{generators → metric_fu/metrics/reek}/reek_spec.rb +1 -1
  126. data/spec/{graphs → metric_fu/metrics/roodi}/roodi_grapher_spec.rb +3 -3
  127. data/spec/{generators → metric_fu/metrics/roodi}/roodi_spec.rb +1 -1
  128. data/spec/{generators → metric_fu/metrics/saikuro}/saikuro_spec.rb +4 -4
  129. data/spec/{graphs → metric_fu/metrics/stats}/stats_grapher_spec.rb +3 -3
  130. data/spec/{generators → metric_fu/metrics/stats}/stats_spec.rb +7 -4
  131. data/spec/{graphs → metric_fu/reporting/graphs}/engines/bluff_spec.rb +3 -3
  132. data/spec/{graphs → metric_fu/reporting/graphs}/engines/gchart_spec.rb +2 -1
  133. data/spec/{base → metric_fu/reporting}/report_spec.rb +5 -3
  134. data/spec/spec_helper.rb +17 -5
  135. data/spec/support/suite.rb +16 -0
  136. metadata +195 -183
  137. data/lib/configuration.rb +0 -227
  138. data/lib/metrics/churn/churn.rb +0 -28
  139. data/lib/version.rb +0 -3
  140. data/spec/base/configuration_spec.rb +0 -277
  141. data/spec/generators/churn_spec.rb +0 -41
  142. data/spec/spec.opts +0 -6
@@ -1,4 +1,4 @@
1
- require File.expand_path(File.dirname(__FILE__) + "/../spec_helper")
1
+ require "spec_helper"
2
2
 
3
3
  describe StatsGrapher do
4
4
  before :each do
@@ -23,7 +23,7 @@ describe StatsGrapher do
23
23
  describe "responding to #get_metrics" do
24
24
  context "when metrics were not generated" do
25
25
  before(:each) do
26
- @metrics = YAML::load(File.open(File.join(File.dirname(__FILE__), "..", "resources", "yml", "metric_missing.yml")))
26
+ @metrics = YAML::load(File.open("#{resources_path}/yml/metric_missing.yml"))
27
27
  @date = "01022003"
28
28
  end
29
29
 
@@ -45,7 +45,7 @@ describe StatsGrapher do
45
45
 
46
46
  context "when metrics have been generated" do
47
47
  before(:each) do
48
- @metrics = YAML::load(File.open(File.join(File.dirname(__FILE__), "..", "resources", "yml", "20090630.yml")))
48
+ @metrics = YAML::load(File.open("#{resources_path}/yml/20090630.yml"))
49
49
  @date = "01022003"
50
50
  end
51
51
 
@@ -1,9 +1,10 @@
1
- require File.expand_path(File.dirname(__FILE__) + "/../spec_helper")
1
+ require "spec_helper"
2
2
 
3
3
  describe Stats do
4
4
  describe "emit method" do
5
5
  it "should gather the raw data" do
6
- MetricFu::Configuration.run {}
6
+ ENV['CC_BUILD_ARTIFACTS'] = nil
7
+ MetricFu.configure.reset
7
8
  File.stub!(:directory?).and_return(true)
8
9
  stats = MetricFu::Stats.new
9
10
  stats.should_receive(:`).with("rake stats > tmp/metric_fu/scratch/stats/stats.txt")
@@ -32,7 +33,8 @@ describe Stats do
32
33
  Code LOC: 915 Test LOC: 2226 Code to Test Ratio: 1:2.4
33
34
 
34
35
  HERE
35
- MetricFu::Configuration.run {}
36
+ ENV['CC_BUILD_ARTIFACTS'] = nil
37
+ MetricFu.configure.reset
36
38
  File.stub!(:directory?).and_return(true)
37
39
  stats = MetricFu::Stats.new
38
40
  File.should_receive(:open).and_return(mock("file", :read => @lines))
@@ -64,7 +66,8 @@ describe Stats do
64
66
 
65
67
  describe "to_h method" do
66
68
  it "should put things into a hash" do
67
- MetricFu::Configuration.run {}
69
+ ENV['CC_BUILD_ARTIFACTS'] = nil
70
+ MetricFu.configure.reset
68
71
  File.stub!(:directory?).and_return(true)
69
72
  stats = MetricFu::Stats.new
70
73
  stats.instance_variable_set(:@stats, "the_stats")
@@ -1,10 +1,10 @@
1
- require File.expand_path(File.dirname(__FILE__) + "/../../spec_helper")
1
+ require "spec_helper"
2
2
 
3
3
  describe "Bluff graphers responding to #graph!" do
4
4
  it "should write chart file" do
5
- MetricFu.configuration
5
+ MetricFu.configure
6
6
  graphs = {}
7
- available_graphs = MetricFu::AVAILABLE_GRAPHS + [:stats]
7
+ available_graphs = MetricFu.graphs
8
8
  available_graphs.each do |graph|
9
9
  grapher_name = graph.to_s.gsub("MetricFu::",'').gsub(/\/(.?)/) { "::#{$1.upcase}" }.gsub(/(?:^|_)(.)/) { $1.upcase }
10
10
  grapher_name = grapher_name+"BluffGrapher"
@@ -1,4 +1,5 @@
1
- require File.expand_path(File.dirname(__FILE__) + "/../../spec_helper")
1
+ require "spec_helper"
2
+
2
3
  describe MetricFu::Grapher do
3
4
  describe "require_graphing_gem" do
4
5
  it "should give a warning if trying to use gchart but gem is not installed" do
@@ -1,4 +1,4 @@
1
- require File.expand_path(File.dirname(__FILE__) + "/../spec_helper")
1
+ require "spec_helper"
2
2
 
3
3
  describe MetricFu do
4
4
 
@@ -15,12 +15,13 @@ describe MetricFu::Report do
15
15
  @report = MetricFu::Report.new
16
16
  end
17
17
 
18
- describe "#to_yaml" do
18
+ describe "#as_yaml" do
19
19
  it 'should call #report_hash' do
20
20
  report_hash = mock('report_hash')
21
21
  report_hash.should_receive(:to_yaml)
22
+
22
23
  @report.should_receive(:report_hash).and_return(report_hash)
23
- @report.to_yaml
24
+ @report.as_yaml
24
25
  end
25
26
  end
26
27
 
@@ -51,6 +52,7 @@ describe MetricFu::Report do
51
52
  report_inst.should_receive(:generate_report).and_return({:a => 'b'})
52
53
  report_inst.should_receive(:respond_to?).and_return(false)
53
54
 
55
+ MetricFu.should_receive(:send).with(report_type).and_return({})
54
56
  MetricFu.should_receive(:const_get).
55
57
  with('Type').and_return(report_type)
56
58
  report_hash = mock('report_hash')
data/spec/spec_helper.rb CHANGED
@@ -1,10 +1,22 @@
1
- require 'rubygems'
2
- require 'spec/autorun'
1
+ require 'rspec/autorun'
3
2
  require 'date'
4
3
  require 'construct'
5
4
 
6
- require File.expand_path File.join(File.dirname(__FILE__), '/../lib/metric_fu.rb')
5
+ # add lib to the load path just like rubygems does
6
+ $:.push File.expand_path("../../lib", __FILE__)
7
+ require 'metric_fu'
7
8
  include MetricFu
8
- def compare_paths(path1,path2)
9
- File.join(MetricFu.root_dir,path1).should == File.join(MetricFu.root_dir,path2)
9
+
10
+ # Requires supporting ruby files with custom matchers and macros, etc,
11
+ # in spec/support/ and its subdirectories.
12
+ Dir[MetricFu.root_dir + "/spec/support/**/*.rb"].each {|f| require f}
13
+
14
+ RSpec.configure do |config|
15
+ # :suite after/before all specs
16
+ # :each ever describe block
17
+ # :all ever it block
18
+
19
+ config.after(:suite) do
20
+ cleanup_test_files
21
+ end
10
22
  end
@@ -0,0 +1,16 @@
1
+
2
+ def compare_paths(path1, path2)
3
+ File.join(MetricFu.root_dir, path1).should == File.join(MetricFu.root_dir, path2)
4
+ end
5
+
6
+
7
+ def cleanup_test_files
8
+ FileUtils.rm_rf(Dir["#{MetricFu.root_dir}/foo"])
9
+ FileUtils.rm_rf(Dir["#{MetricFu.root_dir}/is set"])
10
+ rescue => exception
11
+ end
12
+
13
+
14
+ def resources_path
15
+ "#{MetricFu.root_dir}/spec/resources"
16
+ end
metadata CHANGED
@@ -1,8 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metric_fu
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.3.7.19
5
- prerelease:
4
+ version: 2.1.4.pre
5
+ prerelease: 6
6
6
  platform: ruby
7
7
  authors:
8
8
  - Jake Scruggs
@@ -19,7 +19,7 @@ authors:
19
19
  autorequire:
20
20
  bindir: bin
21
21
  cert_chain: []
22
- date: 2013-01-08 00:00:00.000000000 Z
22
+ date: 2013-01-29 00:00:00.000000000 Z
23
23
  dependencies:
24
24
  - !ruby/object:Gem::Dependency
25
25
  name: flay
@@ -87,12 +87,28 @@ dependencies:
87
87
  version: 2.2.0
88
88
  - !ruby/object:Gem::Dependency
89
89
  name: rails_best_practices
90
+ requirement: !ruby/object:Gem::Requirement
91
+ none: false
92
+ requirements:
93
+ - - '='
94
+ - !ruby/object:Gem::Version
95
+ version: 1.13.2
96
+ type: :runtime
97
+ prerelease: false
98
+ version_requirements: !ruby/object:Gem::Requirement
99
+ none: false
100
+ requirements:
101
+ - - '='
102
+ - !ruby/object:Gem::Version
103
+ version: 1.13.2
104
+ - !ruby/object:Gem::Dependency
105
+ name: rcov
90
106
  requirement: !ruby/object:Gem::Requirement
91
107
  none: false
92
108
  requirements:
93
109
  - - ~>
94
110
  - !ruby/object:Gem::Version
95
- version: 0.10.1
111
+ version: '0.8'
96
112
  type: :runtime
97
113
  prerelease: false
98
114
  version_requirements: !ruby/object:Gem::Requirement
@@ -100,7 +116,23 @@ dependencies:
100
116
  requirements:
101
117
  - - ~>
102
118
  - !ruby/object:Gem::Version
103
- version: 0.10.1
119
+ version: '0.8'
120
+ - !ruby/object:Gem::Dependency
121
+ name: japgolly-Saikuro
122
+ requirement: !ruby/object:Gem::Requirement
123
+ none: false
124
+ requirements:
125
+ - - ! '>='
126
+ - !ruby/object:Gem::Version
127
+ version: 1.1.1.0
128
+ type: :runtime
129
+ prerelease: false
130
+ version_requirements: !ruby/object:Gem::Requirement
131
+ none: false
132
+ requirements:
133
+ - - ! '>='
134
+ - !ruby/object:Gem::Version
135
+ version: 1.1.1.0
104
136
  - !ruby/object:Gem::Dependency
105
137
  name: churn
106
138
  requirement: !ruby/object:Gem::Requirement
@@ -245,40 +277,8 @@ dependencies:
245
277
  - - ! '>='
246
278
  - !ruby/object:Gem::Version
247
279
  version: '0'
248
- - !ruby/object:Gem::Dependency
249
- name: rcov
250
- requirement: !ruby/object:Gem::Requirement
251
- none: false
252
- requirements:
253
- - - ~>
254
- - !ruby/object:Gem::Version
255
- version: '0.8'
256
- type: :runtime
257
- prerelease: false
258
- version_requirements: !ruby/object:Gem::Requirement
259
- none: false
260
- requirements:
261
- - - ~>
262
- - !ruby/object:Gem::Version
263
- version: '0.8'
264
- - !ruby/object:Gem::Dependency
265
- name: japgolly-Saikuro
266
- requirement: !ruby/object:Gem::Requirement
267
- none: false
268
- requirements:
269
- - - ! '>='
270
- - !ruby/object:Gem::Version
271
- version: 1.1.1.0
272
- type: :runtime
273
- prerelease: false
274
- version_requirements: !ruby/object:Gem::Requirement
275
- none: false
276
- requirements:
277
- - - ! '>='
278
- - !ruby/object:Gem::Version
279
- version: 1.1.1.0
280
- description: Code metrics from Flog, Flay, Simplecov-RCov, Saikuro, Churn, Reek, Roodi,
281
- Rails' stats task and Rails Best Practices
280
+ description: Code metrics from Flog, Flay, RCov, Saikuro, Churn, Reek, Roodi, Rails'
281
+ stats task and Rails Best Practices
282
282
  email: github@benjaminfleischer.com
283
283
  executables:
284
284
  - metric_fu
@@ -286,6 +286,7 @@ extensions: []
286
286
  extra_rdoc_files: []
287
287
  files:
288
288
  - .gitignore
289
+ - .rspec
289
290
  - .travis.yml
290
291
  - Gemfile
291
292
  - HISTORY.md
@@ -313,121 +314,132 @@ files:
313
314
  - home_page/styles.css
314
315
  - home_page/title.gif
315
316
  - home_page/title_back.gif
316
- - lib/configuration.rb
317
- - lib/data_structures/careful_array.rb
318
- - lib/data_structures/line_numbers.rb
319
- - lib/data_structures/location.rb
320
- - lib/errors/analysis_error.rb
321
- - lib/initial_requires.rb
322
- - lib/load_files.rb
323
- - lib/logging/mf_debugger.rb
324
317
  - lib/metric_fu.rb
325
- - lib/metrics/base_template.rb
326
- - lib/metrics/churn/churn.rb
327
- - lib/metrics/churn/churn_hotspot.rb
328
- - lib/metrics/churn/template_awesome/churn.html.erb
329
- - lib/metrics/churn/template_standard/churn.html.erb
330
- - lib/metrics/flay/flay.rb
331
- - lib/metrics/flay/flay_grapher.rb
332
- - lib/metrics/flay/flay_hotspot.rb
333
- - lib/metrics/flay/template_awesome/flay.html.erb
334
- - lib/metrics/flay/template_standard/flay.html.erb
335
- - lib/metrics/flog/flog.rb
336
- - lib/metrics/flog/flog_grapher.rb
337
- - lib/metrics/flog/flog_hotspot.rb
338
- - lib/metrics/flog/template_awesome/flog.html.erb
339
- - lib/metrics/flog/template_standard/flog.html.erb
340
- - lib/metrics/generator.rb
341
- - lib/metrics/graph.rb
342
- - lib/metrics/hotspots/analysis/code_issue.rb
343
- - lib/metrics/hotspots/analysis/grouping.rb
344
- - lib/metrics/hotspots/analysis/ranking.rb
345
- - lib/metrics/hotspots/analysis/record.rb
346
- - lib/metrics/hotspots/analysis/scoring_strategies.rb
347
- - lib/metrics/hotspots/analysis/table.rb
348
- - lib/metrics/hotspots/hotspot_analyzer.rb
349
- - lib/metrics/hotspots/hotspots.rb
350
- - lib/metrics/hotspots/template_awesome/hotspots.html.erb
351
- - lib/metrics/hotspots/template_standard/hotspots.html.erb
352
- - lib/metrics/rails_best_practices/rails_best_practices.rb
353
- - lib/metrics/rails_best_practices/rails_best_practices_grapher.rb
354
- - lib/metrics/rails_best_practices/template_awesome/rails_best_practices.html.erb
355
- - lib/metrics/rails_best_practices/template_standard/rails_best_practices.html.erb
356
- - lib/metrics/rcov/rcov.rb
357
- - lib/metrics/rcov/rcov_grapher.rb
358
- - lib/metrics/rcov/rcov_hotspot.rb
359
- - lib/metrics/rcov/template_awesome/rcov.html.erb
360
- - lib/metrics/rcov/template_standard/rcov.html.erb
361
- - lib/metrics/reek/reek.rb
362
- - lib/metrics/reek/reek_grapher.rb
363
- - lib/metrics/reek/reek_hotspot.rb
364
- - lib/metrics/reek/template_awesome/reek.html.erb
365
- - lib/metrics/reek/template_standard/reek.html.erb
366
- - lib/metrics/roodi/roodi.rb
367
- - lib/metrics/roodi/roodi_grapher.rb
368
- - lib/metrics/roodi/roodi_hotspot.rb
369
- - lib/metrics/roodi/template_awesome/roodi.html.erb
370
- - lib/metrics/roodi/template_standard/roodi.html.erb
371
- - lib/metrics/saikuro/saikuro.rb
372
- - lib/metrics/saikuro/saikuro_hotspot.rb
373
- - lib/metrics/saikuro/template_awesome/saikuro.html.erb
374
- - lib/metrics/saikuro/template_standard/saikuro.html.erb
375
- - lib/metrics/stats/stats.rb
376
- - lib/metrics/stats/stats_grapher.rb
377
- - lib/metrics/stats/stats_hotspot.rb
378
- - lib/metrics/stats/template_awesome/stats.html.erb
379
- - lib/metrics/stats/template_standard/stats.html.erb
380
- - lib/reporting/graphs/engines/bluff.rb
381
- - lib/reporting/graphs/engines/gchart.rb
382
- - lib/reporting/graphs/grapher.rb
383
- - lib/reporting/report.rb
384
- - lib/reporting/templates/awesome/awesome_template.rb
385
- - lib/reporting/templates/awesome/css/buttons.css
386
- - lib/reporting/templates/awesome/css/default.css
387
- - lib/reporting/templates/awesome/css/integrity.css
388
- - lib/reporting/templates/awesome/css/reset.css
389
- - lib/reporting/templates/awesome/css/syntax.css
390
- - lib/reporting/templates/awesome/index.html.erb
391
- - lib/reporting/templates/awesome/layout.html.erb
392
- - lib/reporting/templates/javascripts/bluff-min.js
393
- - lib/reporting/templates/javascripts/excanvas.js
394
- - lib/reporting/templates/javascripts/js-class.js
395
- - lib/reporting/templates/standard/default.css
396
- - lib/reporting/templates/standard/index.html.erb
397
- - lib/reporting/templates/standard/standard_template.rb
398
- - lib/run.rb
399
- - lib/tasks/metric_fu.rake
400
- - lib/version.rb
318
+ - lib/metric_fu/configuration.rb
319
+ - lib/metric_fu/data_structures/careful_array.rb
320
+ - lib/metric_fu/data_structures/line_numbers.rb
321
+ - lib/metric_fu/data_structures/location.rb
322
+ - lib/metric_fu/errors/analysis_error.rb
323
+ - lib/metric_fu/initial_requires.rb
324
+ - lib/metric_fu/load_files.rb
325
+ - lib/metric_fu/logging/mf_debugger.rb
326
+ - lib/metric_fu/metrics/base_template.rb
327
+ - lib/metric_fu/metrics/churn/churn.rb
328
+ - lib/metric_fu/metrics/churn/churn_hotspot.rb
329
+ - lib/metric_fu/metrics/churn/init.rb
330
+ - lib/metric_fu/metrics/churn/template_awesome/churn.html.erb
331
+ - lib/metric_fu/metrics/churn/template_standard/churn.html.erb
332
+ - lib/metric_fu/metrics/flay/flay.rb
333
+ - lib/metric_fu/metrics/flay/flay_grapher.rb
334
+ - lib/metric_fu/metrics/flay/flay_hotspot.rb
335
+ - lib/metric_fu/metrics/flay/init.rb
336
+ - lib/metric_fu/metrics/flay/template_awesome/flay.html.erb
337
+ - lib/metric_fu/metrics/flay/template_standard/flay.html.erb
338
+ - lib/metric_fu/metrics/flog/flog.rb
339
+ - lib/metric_fu/metrics/flog/flog_grapher.rb
340
+ - lib/metric_fu/metrics/flog/flog_hotspot.rb
341
+ - lib/metric_fu/metrics/flog/init.rb
342
+ - lib/metric_fu/metrics/flog/template_awesome/flog.html.erb
343
+ - lib/metric_fu/metrics/flog/template_standard/flog.html.erb
344
+ - lib/metric_fu/metrics/generator.rb
345
+ - lib/metric_fu/metrics/graph.rb
346
+ - lib/metric_fu/metrics/hotspots/analysis/code_issue.rb
347
+ - lib/metric_fu/metrics/hotspots/analysis/grouping.rb
348
+ - lib/metric_fu/metrics/hotspots/analysis/ranking.rb
349
+ - lib/metric_fu/metrics/hotspots/analysis/record.rb
350
+ - lib/metric_fu/metrics/hotspots/analysis/scoring_strategies.rb
351
+ - lib/metric_fu/metrics/hotspots/analysis/table.rb
352
+ - lib/metric_fu/metrics/hotspots/hotspot_analyzer.rb
353
+ - lib/metric_fu/metrics/hotspots/hotspots.rb
354
+ - lib/metric_fu/metrics/hotspots/init.rb
355
+ - lib/metric_fu/metrics/hotspots/template_awesome/hotspots.html.erb
356
+ - lib/metric_fu/metrics/hotspots/template_standard/hotspots.html.erb
357
+ - lib/metric_fu/metrics/rails_best_practices/init.rb
358
+ - lib/metric_fu/metrics/rails_best_practices/rails_best_practices.rb
359
+ - lib/metric_fu/metrics/rails_best_practices/rails_best_practices_grapher.rb
360
+ - lib/metric_fu/metrics/rails_best_practices/template_awesome/rails_best_practices.html.erb
361
+ - lib/metric_fu/metrics/rails_best_practices/template_standard/rails_best_practices.html.erb
362
+ - lib/metric_fu/metrics/rcov/init.rb
363
+ - lib/metric_fu/metrics/rcov/rcov.rb
364
+ - lib/metric_fu/metrics/rcov/rcov_grapher.rb
365
+ - lib/metric_fu/metrics/rcov/rcov_hotspot.rb
366
+ - lib/metric_fu/metrics/rcov/template_awesome/rcov.html.erb
367
+ - lib/metric_fu/metrics/rcov/template_standard/rcov.html.erb
368
+ - lib/metric_fu/metrics/reek/init.rb
369
+ - lib/metric_fu/metrics/reek/reek.rb
370
+ - lib/metric_fu/metrics/reek/reek_grapher.rb
371
+ - lib/metric_fu/metrics/reek/reek_hotspot.rb
372
+ - lib/metric_fu/metrics/reek/template_awesome/reek.html.erb
373
+ - lib/metric_fu/metrics/reek/template_standard/reek.html.erb
374
+ - lib/metric_fu/metrics/roodi/init.rb
375
+ - lib/metric_fu/metrics/roodi/roodi.rb
376
+ - lib/metric_fu/metrics/roodi/roodi_grapher.rb
377
+ - lib/metric_fu/metrics/roodi/roodi_hotspot.rb
378
+ - lib/metric_fu/metrics/roodi/template_awesome/roodi.html.erb
379
+ - lib/metric_fu/metrics/roodi/template_standard/roodi.html.erb
380
+ - lib/metric_fu/metrics/saikuro/init.rb
381
+ - lib/metric_fu/metrics/saikuro/saikuro.rb
382
+ - lib/metric_fu/metrics/saikuro/saikuro_hotspot.rb
383
+ - lib/metric_fu/metrics/saikuro/template_awesome/saikuro.html.erb
384
+ - lib/metric_fu/metrics/saikuro/template_standard/saikuro.html.erb
385
+ - lib/metric_fu/metrics/stats/init.rb
386
+ - lib/metric_fu/metrics/stats/stats.rb
387
+ - lib/metric_fu/metrics/stats/stats_grapher.rb
388
+ - lib/metric_fu/metrics/stats/stats_hotspot.rb
389
+ - lib/metric_fu/metrics/stats/template_awesome/stats.html.erb
390
+ - lib/metric_fu/metrics/stats/template_standard/stats.html.erb
391
+ - lib/metric_fu/reporting/graphs/engines/bluff.rb
392
+ - lib/metric_fu/reporting/graphs/engines/gchart.rb
393
+ - lib/metric_fu/reporting/graphs/engines/init.rb
394
+ - lib/metric_fu/reporting/graphs/grapher.rb
395
+ - lib/metric_fu/reporting/report.rb
396
+ - lib/metric_fu/reporting/templates/awesome/awesome_template.rb
397
+ - lib/metric_fu/reporting/templates/awesome/css/buttons.css
398
+ - lib/metric_fu/reporting/templates/awesome/css/default.css
399
+ - lib/metric_fu/reporting/templates/awesome/css/integrity.css
400
+ - lib/metric_fu/reporting/templates/awesome/css/reset.css
401
+ - lib/metric_fu/reporting/templates/awesome/css/syntax.css
402
+ - lib/metric_fu/reporting/templates/awesome/index.html.erb
403
+ - lib/metric_fu/reporting/templates/awesome/layout.html.erb
404
+ - lib/metric_fu/reporting/templates/javascripts/bluff-min.js
405
+ - lib/metric_fu/reporting/templates/javascripts/excanvas.js
406
+ - lib/metric_fu/reporting/templates/javascripts/js-class.js
407
+ - lib/metric_fu/reporting/templates/standard/default.css
408
+ - lib/metric_fu/reporting/templates/standard/index.html.erb
409
+ - lib/metric_fu/reporting/templates/standard/standard_template.rb
410
+ - lib/metric_fu/run.rb
411
+ - lib/metric_fu/tasks/metric_fu.rake
412
+ - lib/metric_fu/version.rb
401
413
  - metric_fu.gemspec
402
- - spec/base/base_template_spec.rb
403
- - spec/base/configuration_spec.rb
404
- - spec/base/generator_spec.rb
405
- - spec/base/graph_spec.rb
406
- - spec/base/hotspot_analyzer_spec.rb
407
- - spec/base/line_numbers_spec.rb
408
- - spec/base/location_spec.rb
409
- - spec/base/ranking_spec.rb
410
- - spec/base/report_spec.rb
411
- - spec/base/table_spec.rb
412
- - spec/generators/churn_spec.rb
413
- - spec/generators/flay_spec.rb
414
- - spec/generators/flog_spec.rb
415
- - spec/generators/hotspots_spec.rb
416
- - spec/generators/rails_best_practices_spec.rb
417
- - spec/generators/rcov_spec.rb
418
- - spec/generators/reek_spec.rb
419
- - spec/generators/roodi_spec.rb
420
- - spec/generators/saikuro_spec.rb
421
- - spec/generators/stats_spec.rb
422
- - spec/graphs/engines/bluff_spec.rb
423
- - spec/graphs/engines/gchart_spec.rb
424
- - spec/graphs/flay_grapher_spec.rb
425
- - spec/graphs/flog_grapher_spec.rb
426
- - spec/graphs/rails_best_practices_grapher_spec.rb
427
- - spec/graphs/rcov_grapher_spec.rb
428
- - spec/graphs/reek_grapher_spec.rb
429
- - spec/graphs/roodi_grapher_spec.rb
430
- - spec/graphs/stats_grapher_spec.rb
414
+ - spec/metric_fu/configuration_spec.rb
415
+ - spec/metric_fu/data_structures/line_numbers_spec.rb
416
+ - spec/metric_fu/data_structures/location_spec.rb
417
+ - spec/metric_fu/metrics/base_template_spec.rb
418
+ - spec/metric_fu/metrics/churn/churn_spec.rb
419
+ - spec/metric_fu/metrics/flay/flay_grapher_spec.rb
420
+ - spec/metric_fu/metrics/flay/flay_spec.rb
421
+ - spec/metric_fu/metrics/flog/flog_grapher_spec.rb
422
+ - spec/metric_fu/metrics/flog/flog_spec.rb
423
+ - spec/metric_fu/metrics/generator_spec.rb
424
+ - spec/metric_fu/metrics/graph_spec.rb
425
+ - spec/metric_fu/metrics/hotspots/analysis/ranking_spec.rb
426
+ - spec/metric_fu/metrics/hotspots/analysis/table_spec.rb
427
+ - spec/metric_fu/metrics/hotspots/hotspot_analyzer_spec.rb
428
+ - spec/metric_fu/metrics/hotspots/hotspots_spec.rb
429
+ - spec/metric_fu/metrics/rails_best_practices/rails_best_practices_grapher_spec.rb
430
+ - spec/metric_fu/metrics/rails_best_practices/rails_best_practices_spec.rb
431
+ - spec/metric_fu/metrics/rcov/rcov_grapher_spec.rb
432
+ - spec/metric_fu/metrics/rcov/rcov_spec.rb
433
+ - spec/metric_fu/metrics/reek/reek_grapher_spec.rb
434
+ - spec/metric_fu/metrics/reek/reek_spec.rb
435
+ - spec/metric_fu/metrics/roodi/roodi_grapher_spec.rb
436
+ - spec/metric_fu/metrics/roodi/roodi_spec.rb
437
+ - spec/metric_fu/metrics/saikuro/saikuro_spec.rb
438
+ - spec/metric_fu/metrics/stats/stats_grapher_spec.rb
439
+ - spec/metric_fu/metrics/stats/stats_spec.rb
440
+ - spec/metric_fu/reporting/graphs/engines/bluff_spec.rb
441
+ - spec/metric_fu/reporting/graphs/engines/gchart_spec.rb
442
+ - spec/metric_fu/reporting/report_spec.rb
431
443
  - spec/resources/line_numbers/foo.rb
432
444
  - spec/resources/line_numbers/module.rb
433
445
  - spec/resources/line_numbers/module_surrounds_class.rb
@@ -438,8 +450,8 @@ files:
438
450
  - spec/resources/saikuro_sfiles/thing.rb_cyclo.html
439
451
  - spec/resources/yml/20090630.yml
440
452
  - spec/resources/yml/metric_missing.yml
441
- - spec/spec.opts
442
453
  - spec/spec_helper.rb
454
+ - spec/support/suite.rb
443
455
  homepage: http://github.com/metricfu/metric_fu
444
456
  licenses:
445
457
  - MIT
@@ -466,35 +478,35 @@ signing_key:
466
478
  specification_version: 3
467
479
  summary: A fistful of code metrics, with awesome templates and graphs
468
480
  test_files:
469
- - spec/base/base_template_spec.rb
470
- - spec/base/configuration_spec.rb
471
- - spec/base/generator_spec.rb
472
- - spec/base/graph_spec.rb
473
- - spec/base/hotspot_analyzer_spec.rb
474
- - spec/base/line_numbers_spec.rb
475
- - spec/base/location_spec.rb
476
- - spec/base/ranking_spec.rb
477
- - spec/base/report_spec.rb
478
- - spec/base/table_spec.rb
479
- - spec/generators/churn_spec.rb
480
- - spec/generators/flay_spec.rb
481
- - spec/generators/flog_spec.rb
482
- - spec/generators/hotspots_spec.rb
483
- - spec/generators/rails_best_practices_spec.rb
484
- - spec/generators/rcov_spec.rb
485
- - spec/generators/reek_spec.rb
486
- - spec/generators/roodi_spec.rb
487
- - spec/generators/saikuro_spec.rb
488
- - spec/generators/stats_spec.rb
489
- - spec/graphs/engines/bluff_spec.rb
490
- - spec/graphs/engines/gchart_spec.rb
491
- - spec/graphs/flay_grapher_spec.rb
492
- - spec/graphs/flog_grapher_spec.rb
493
- - spec/graphs/rails_best_practices_grapher_spec.rb
494
- - spec/graphs/rcov_grapher_spec.rb
495
- - spec/graphs/reek_grapher_spec.rb
496
- - spec/graphs/roodi_grapher_spec.rb
497
- - spec/graphs/stats_grapher_spec.rb
481
+ - spec/metric_fu/configuration_spec.rb
482
+ - spec/metric_fu/data_structures/line_numbers_spec.rb
483
+ - spec/metric_fu/data_structures/location_spec.rb
484
+ - spec/metric_fu/metrics/base_template_spec.rb
485
+ - spec/metric_fu/metrics/churn/churn_spec.rb
486
+ - spec/metric_fu/metrics/flay/flay_grapher_spec.rb
487
+ - spec/metric_fu/metrics/flay/flay_spec.rb
488
+ - spec/metric_fu/metrics/flog/flog_grapher_spec.rb
489
+ - spec/metric_fu/metrics/flog/flog_spec.rb
490
+ - spec/metric_fu/metrics/generator_spec.rb
491
+ - spec/metric_fu/metrics/graph_spec.rb
492
+ - spec/metric_fu/metrics/hotspots/analysis/ranking_spec.rb
493
+ - spec/metric_fu/metrics/hotspots/analysis/table_spec.rb
494
+ - spec/metric_fu/metrics/hotspots/hotspot_analyzer_spec.rb
495
+ - spec/metric_fu/metrics/hotspots/hotspots_spec.rb
496
+ - spec/metric_fu/metrics/rails_best_practices/rails_best_practices_grapher_spec.rb
497
+ - spec/metric_fu/metrics/rails_best_practices/rails_best_practices_spec.rb
498
+ - spec/metric_fu/metrics/rcov/rcov_grapher_spec.rb
499
+ - spec/metric_fu/metrics/rcov/rcov_spec.rb
500
+ - spec/metric_fu/metrics/reek/reek_grapher_spec.rb
501
+ - spec/metric_fu/metrics/reek/reek_spec.rb
502
+ - spec/metric_fu/metrics/roodi/roodi_grapher_spec.rb
503
+ - spec/metric_fu/metrics/roodi/roodi_spec.rb
504
+ - spec/metric_fu/metrics/saikuro/saikuro_spec.rb
505
+ - spec/metric_fu/metrics/stats/stats_grapher_spec.rb
506
+ - spec/metric_fu/metrics/stats/stats_spec.rb
507
+ - spec/metric_fu/reporting/graphs/engines/bluff_spec.rb
508
+ - spec/metric_fu/reporting/graphs/engines/gchart_spec.rb
509
+ - spec/metric_fu/reporting/report_spec.rb
498
510
  - spec/resources/line_numbers/foo.rb
499
511
  - spec/resources/line_numbers/module.rb
500
512
  - spec/resources/line_numbers/module_surrounds_class.rb
@@ -505,5 +517,5 @@ test_files:
505
517
  - spec/resources/saikuro_sfiles/thing.rb_cyclo.html
506
518
  - spec/resources/yml/20090630.yml
507
519
  - spec/resources/yml/metric_missing.yml
508
- - spec/spec.opts
509
520
  - spec/spec_helper.rb
521
+ - spec/support/suite.rb