Sha256: 4d007912d7840d8a859373a243bc06685845d058425038312f22d0aaab26455c

Contents?: true

Size: 560 Bytes

Versions: 3

Compression:

Stored size: 560 Bytes

Contents

# frozen_string_literal: true

module NeetoCompliance
  class SimplecovConfigVerifier < Base
    def test_helper
      "test/test_helper.rb"
    end

    def valid?
      @errors = []

      check_file = Set.new(File.readlines(test_helper).collect(&:chomp))

      if check_file.include?("NeetoCommonsBackend.simplecov_config")
        @errors << "Remove NeetoCommons.simplecov_config from #{test_helper}"
      end

      @errors.length == 0
    end

    def autofix_suggestion
      @errors.join("\n").yellow
    end

    def auto_correct!
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
neetob-0.1.2 neeto_compliance/lib/neeto_compliance/verifiers/simplecov_config_verifier.rb
neetob-0.1.1 /Users/chiragshah/Workspace/bigbinary/neeto/neetob/neeto_compliance/lib/neeto_compliance/verifiers/simplecov_config_verifier.rb
neetob-0.1.0 /Users/chiragshah/Workspace/bigbinary/neeto/neetob/neeto_compliance/lib/neeto_compliance/verifiers/simplecov_config_verifier.rb