Sha256: 8bdd17a424e15e81bd645974d408517c2b29fe8772a9eb000c6752bb14ff816c

Contents?: true

Size: 819 Bytes

Versions: 4

Compression:

Stored size: 819 Bytes

Contents

# frozen_string_literal: true

require "neeto_compliance/sync_neeto_commons"
require "neeto_compliance/sync_neeto_commons/sync_test_support"

module NeetoCompliance
  class SyncNeetoCommonsVerifier < Base
    class TestSupportFilesVerifier
      def process
        return false unless support_folder_exist?

        non_complied_test_support_files.empty?
      end

      private

        def support_folder_exist?
          File.directory?(NeetoCompliance::SyncNeetoCommons::SyncTestSupport::SUPPORT_DIR)
        end

        def non_complied_test_support_files
          NeetoCompliance::SyncNeetoCommons::SyncTestSupport.SUPPORT_FILES.select do |file|
            !system("cat #{NeetoCompliance::SyncNeetoCommons.neeto_commons_url}#{file} | diff #{file} - 1> /dev/null")
          end
        end
    end
  end
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
neeto-compliance-1.0.58 lib/neeto_compliance/verifiers/sync_neeto_commons_verifier/test_support_files_verifier.rb
neetob-0.1.2 neeto_compliance/lib/neeto_compliance/verifiers/sync_neeto_commons_verifier/test_support_files_verifier.rb
neetob-0.1.1 /Users/chiragshah/Workspace/bigbinary/neeto/neetob/neeto_compliance/lib/neeto_compliance/verifiers/sync_neeto_commons_verifier/test_support_files_verifier.rb
neetob-0.1.0 /Users/chiragshah/Workspace/bigbinary/neeto/neetob/neeto_compliance/lib/neeto_compliance/verifiers/sync_neeto_commons_verifier/test_support_files_verifier.rb