Sha256: 110ef0a3ddf45c7b9f042d0c45359d1d447770a5f9c2abd814bc5f373ad2540b

Contents?: true

Size: 275 Bytes

Versions: 16

Compression:

Stored size: 275 Bytes

Contents

module Pact

  #TODO move to external file for reuse
  module FileName
    def file_name consumer_name, provider_name
      "#{filenamify(consumer_name)}-#{filenamify(provider_name)}.json"
    end

    def filenamify name
      name.downcase.gsub(/\s/, '_')
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
pact-1.1.1 lib/pact/consumer_contract/file_name.rb
pact-1.1.0 lib/pact/consumer_contract/file_name.rb
pact-1.1.0.rc5 lib/pact/consumer_contract/file_name.rb
pact-1.1.0.rc4 lib/pact/consumer_contract/file_name.rb
pact-1.1.0.rc3 lib/pact/consumer_contract/file_name.rb
pact-1.0.39 lib/pact/consumer_contract/file_name.rb
pact-1.1.0.rc2 lib/pact/consumer_contract/file_name.rb
pact-1.0.38 lib/pact/consumer_contract/file_name.rb
pact-1.1.0.rc1 lib/pact/consumer_contract/file_name.rb
pact-1.0.37 lib/pact/consumer_contract/file_name.rb
pact-1.0.36 lib/pact/consumer_contract/file_name.rb
pact-1.0.35 lib/pact/consumer_contract/file_name.rb
pact-1.0.34 lib/pact/consumer_contract/file_name.rb
pact-1.0.33 lib/pact/consumer_contract/file_name.rb
pact-1.0.32 lib/pact/consumer_contract/file_name.rb
pact-1.0.31 lib/pact/consumer_contract/file_name.rb