Sha256: c30ea4aff7c14d71f2c6bdab9d65378cf0bbf6bf4b59e8f90cbc74de45c5f266

Contents?: true

Size: 409 Bytes

Versions: 81

Compression:

Stored size: 409 Bytes

Contents

require 'rack'
require 'rack/cascade'

module Pact
  module MockService
    module ControlServer
      class MockServices < Rack::Cascade

        def add app
          mock_services << app
          super
        end

        def shutdown
          mock_services.each(&:shutdown)
        end

        private

        def mock_services
          @mock_services ||= []
        end
      end
    end
  end
end

Version data entries

81 entries across 81 versions & 2 rubygems

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