Sha256: ab148e3976b5dc9f352b7e7ccf00e6b02543c6507f08dd8bb2c3369df3bbdcaf

Contents?: true

Size: 488 Bytes

Versions: 4

Compression:

Stored size: 488 Bytes

Contents

require 'simplabs/excellent/checks/base'

module Simplabs

  module Excellent

    module Checks

      class LineCountCheck < Base #:nodoc:

        def initialize(interesting_contexts, threshold)
          super()
          @interesting_contexts = interesting_contexts
          @threshold            = threshold
        end

        def evaluate(context)
          add_warning(*warning_args(context)) unless context.line_count <= @threshold
        end

      end

    end

  end

end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
excellent-1.7.2 lib/simplabs/excellent/checks/line_count_check.rb
excellent-1.7.1 lib/simplabs/excellent/checks/line_count_check.rb
excellent-1.7.0 lib/simplabs/excellent/checks/line_count_check.rb
excellent-1.6.0 lib/simplabs/excellent/checks/line_count_check.rb