Sha256: 72c1c8aa5978684c2fa66c39c725e71e75dcddfc96c887be5f354a45830ec683

Contents?: true

Size: 544 Bytes

Versions: 12

Compression:

Stored size: 544 Bytes

Contents

MetricFu.reporting_require { 'graphs/grapher' }
module MetricFu
  class StatsGrapher < Grapher
    attr_accessor :loc_counts, :lot_counts, :labels

    def initialize
      super
      self.loc_counts = []
      self.lot_counts = []
      self.labels = {}
    end

    def get_metrics(metrics, date)
      if metrics && metrics[:stats]
        self.loc_counts.push(metrics[:stats][:codeLOC].to_i)
        self.lot_counts.push(metrics[:stats][:testLOC].to_i)
        self.labels.update( { self.labels.size => date })
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
metric_fu-4.4.4 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.4.3 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.4.2 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.4.1 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.4.0 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.3.1 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.3.0 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.2.1 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.2.0 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.1.3 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.1.2 lib/metric_fu/metrics/stats/stats_grapher.rb
metric_fu-4.1.1 lib/metric_fu/metrics/stats/stats_grapher.rb