Sha256: 2940323cfe4990a190af04ea3c41cfb590effbb6a1f79e1c640e2fb1036b4fef

Contents?: true

Size: 1.74 KB

Versions: 14

Compression:

Stored size: 1.74 KB

Contents

<h3>Flog Results</h3>
<p><a href='http://ruby.sadi.st/Flog.html'>Flog</a> measures code complexity.</p>

<%= render_partial 'graph', {:graph_name => 'flog'} %>

<h2>Total Flog score for all methods: <%= round_to_tenths @flog[:total]%></h2>
<h2>Average Flog score for all methods: <%= round_to_tenths @flog[:average]%></h2>

<table>
  <tr>
    <th>File</th>
    <th>Total score</th>
    <th>Methods</th>
    <th>Average score</th>
    <th>Highest score</th>
  </tr>
    <% @flog[:method_containers].each do |method_container| %>
    <tr>
      <td><a href="#<%= method_container[:path].gsub(/[^a-z]+/, '_') %>"><%= method_container[:path] %></a></td>
      <td><%= round_to_tenths  method_container[:total_score] %></td>
      <td><%= method_container[:methods].size %></td>
      <td><%= round_to_tenths method_container[:average_score] %></td>
      <td><%= round_to_tenths method_container[:highest_score] %></td>
    </tr>
  <% end %>
</table>

<% @flog[:method_containers].each do |method_container| %>
  <h2 id="<%= method_container[:path].gsub(/[^a-z]+/, '_') %>"><%= link_to_filename(method_container[:path]) %></h2>

    <% method_container[:methods].each do |full_method_name, method_info| %>
      <% path, line = method_info[:path].split(":") if method_info[:path] %>
      <p><%= link_to_filename(path, line, full_method_name) %></p>
      <p>Total Score: <%= round_to_tenths method_info[:score]%></p>
      <table>
        <tr>
          <th>Score</th>
          <th>Operator</th>
        </tr>
        <% method_info[:operators].each do |operator, score| %>
          <tr>
            <td><%= round_to_tenths score %></td>
            <td><%= operator %></td>
          </tr>
        <% end %>
      </table>
    <% end %>
<% end %>

<%= render_partial 'report_footer' %>

Version data entries

14 entries across 14 versions & 3 rubygems

Version Path
metric_fu-4.13.0 lib/metric_fu/metrics/flog/report.html.erb
fastruby-metric_fu-5.0.0 lib/metric_fu/metrics/flog/report.html.erb
code_metric_fu-4.14.4 lib/metric_fu/metrics/flog/report.html.erb
code_metric_fu-4.14.3 lib/metric_fu/metrics/flog/report.html.erb
code_metric_fu-4.14.2 lib/metric_fu/metrics/flog/report.html.erb
code_metric_fu-4.14.1 lib/metric_fu/metrics/flog/report.html.erb
code_metric_fu-4.14.0 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.12.0 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.11.4 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.11.3 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.11.2 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.11.1 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.11.0 lib/metric_fu/metrics/flog/report.html.erb
metric_fu-4.10.0 lib/metric_fu/metrics/flog/template_awesome/flog.html.erb