Sha256: 6cc6cd54c72113903d0d444a6b37c9109a06e6368f591085aa72f3e2dd770c3d

Contents?: true

Size: 711 Bytes

Versions: 110

Compression:

Stored size: 711 Bytes

Contents

module Pact

  def self.consumer_world
    @consumer_world ||= Pact::Consumer::World.new
  end

  # internal api, for testing only
  def self.clear_consumer_world
    @consumer_world = nil
  end

  module Consumer
    class World

      def initialize
        @any_pact_examples_ran = false
      end

      def consumer_contract_builders
        @consumer_contract_builders ||= []
      end

      def add_consumer_contract_builder consumer_contract_builder
        consumer_contract_builders << consumer_contract_builder
      end

      def register_pact_example_ran
        @any_pact_examples_ran = true
      end

      def any_pact_examples_ran?
        @any_pact_examples_ran
      end

    end
  end
end

Version data entries

110 entries across 110 versions & 1 rubygems

Version Path
pact-1.17.0 lib/pact/consumer/world.rb
pact-1.16.1 lib/pact/consumer/world.rb
pact-1.16.0 lib/pact/consumer/world.rb
pact-1.15.0 lib/pact/consumer/world.rb
pact-1.14.0 lib/pact/consumer/world.rb
pact-1.13.0 lib/pact/consumer/world.rb
pact-1.12.1 lib/pact/consumer/world.rb
pact-1.12.0 lib/pact/consumer/world.rb
pact-1.11.1 lib/pact/consumer/world.rb
pact-1.11.0 lib/pact/consumer/world.rb
pact-1.10.0 lib/pact/consumer/world.rb
pact-1.9.6 lib/pact/consumer/world.rb
pact-1.9.5 lib/pact/consumer/world.rb
pact-1.9.4 lib/pact/consumer/world.rb
pact-1.9.3 lib/pact/consumer/world.rb
pact-1.9.2 lib/pact/consumer/world.rb
pact-1.9.1 lib/pact/consumer/world.rb
pact-1.9.0 lib/pact/consumer/world.rb
pact-1.8.1 lib/pact/consumer/world.rb
pact-1.8.0 lib/pact/consumer/world.rb