Sha256: 257a66cbc0098f201e9f54b22474f36850d4c5dc7f891c77e3d6796b43759ceb
Contents?: true
Size: 853 Bytes
Versions: 50
Compression:
Stored size: 853 Bytes
Contents
require 'pact_broker/api/resources/base_resource' require 'pact_broker/configuration' require 'pact_broker/api/decorators/provider_pacts_decorator' module PactBroker module Api module Resources class LatestProviderPacts < BaseResource def content_types_provided [["application/hal+json", :to_json]] end def allowed_methods ["GET"] end def resource_exists? pacticipant_service.find_pacticipant_by_name(provider_name) end def to_json PactBroker::Api::Decorators::ProviderPactsDecorator.new(pacts).to_json(user_options: decorator_context(identifier_from_path)) end def pacts pact_service.find_latest_pact_versions_for_provider provider_name, tag: identifier_from_path[:tag] end end end end end
Version data entries
50 entries across 50 versions & 1 rubygems