Sha256: d1e4c887e54453b3ea6ca471718d27f7e43ad6e28a21b0c94880bf38e4242fd6

Contents?: true

Size: 348 Bytes

Versions: 15

Compression:

Stored size: 348 Bytes

Contents

# frozen_string_literal: true

module Chutney
  # base class for all formatters
  class Formatter
    attr_accessor :results

    def initialize
      @results = {}
    end

    def files
      results.map { |k, _v| k }
    end

    def files_with_issues
      results.filter { |_k, v| v.any? { |r| r[:issues].count.positive? } }
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
chutney-3.10.0 lib/chutney/formatter.rb
chutney-3.9.0 lib/chutney/formatter.rb
chutney-3.8.2 lib/chutney/formatter.rb
chutney-3.8.1 lib/chutney/formatter.rb
chutney-3.8.0 lib/chutney/formatter.rb
chutney-3.7.0 lib/chutney/formatter.rb
chutney-3.6.0 lib/chutney/formatter.rb
chutney-3.5.0 lib/chutney/formatter.rb
chutney-3.3.0 lib/chutney/formatter.rb
chutney-3.2.1 lib/chutney/formatter.rb
chutney-3.2.0 lib/chutney/formatter.rb
chutney-3.1.1 lib/chutney/formatter.rb
chutney-3.1.0 lib/chutney/formatter.rb
chutney-3.0.1 lib/chutney/formatter.rb
chutney-3.0.0 lib/chutney/formatter.rb