Sha256: 63affd4cb17ddebf3e315d6435c107a666b93e19ab4ed65b24c2def8e80af812

Contents?: true

Size: 705 Bytes

Versions: 7

Compression:

Stored size: 705 Bytes

Contents

# frozen_string_literal: true
require 'rubycritic/analysers/helpers/methods_counter'
require 'rubycritic/analysers/helpers/modules_locator'
require 'rubycritic/colorize'

module RubyCritic
  module Analyser
    class Attributes
      include Colorize
      def initialize(analysed_modules)
        @analysed_modules = analysed_modules
      end

      def run
        @analysed_modules.each do |analysed_module|
          analysed_module.methods_count = MethodsCounter.new(analysed_module).count
          analysed_module.name = ModulesLocator.new(analysed_module).first_name
          print green '.'
        end
        puts ''
      end

      def to_s
        'attributes'
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
rubycritic-3.2.0 lib/rubycritic/analysers/attributes.rb
rubycritic-3.1.3 lib/rubycritic/analysers/attributes.rb
rubycritic-3.1.2 lib/rubycritic/analysers/attributes.rb
rubycritic-3.1.1 lib/rubycritic/analysers/attributes.rb
rubycritic-3.1.0 lib/rubycritic/analysers/attributes.rb
rubycritic-3.0.0 lib/rubycritic/analysers/attributes.rb
rubycritic-2.9.4 lib/rubycritic/analysers/attributes.rb