Sha256: 6b3a155802eb32e7bf164832d1392dc5cc30251efc56e915aa56dc5c8ec4fe95

Contents?: true

Size: 544 Bytes

Versions: 80

Compression:

Stored size: 544 Bytes

Contents

module Pact
  module MockService
    module Interactions
      class VerifiedInteractions < Array

        def << interaction
          unless find_matching_description_and_provider_state interaction
            super
          end
        end

        def find_matching_description_and_provider_state interaction
          find do |candidate_interaction|
            candidate_interaction.matches_criteria?(description: interaction.description, provider_state: interaction.provider_state)
          end
        end
      end
    end
  end
end

Version data entries

80 entries across 80 versions & 2 rubygems

Version Path
pact-mock_service-3.12.3 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.12.2 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.12.1 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.12.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.11.2 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.11.1 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.11.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.10.0 lib/pact/mock_service/interactions/verified_interactions.rb
hs-pact-mock_service-3.9.2 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.9.1 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.9.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.8.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.7.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.6.2 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.6.1 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.6.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.5.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.4.0 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.3.1 lib/pact/mock_service/interactions/verified_interactions.rb
pact-mock_service-3.3.0 lib/pact/mock_service/interactions/verified_interactions.rb