class PactBroker::Matrix::SelectorIgnorer
Attributes
resolved_ignore_selectors[R]
Public Class Methods
new(resolved_ignore_selectors)
click to toggle source
@param [Array<PactBroker::Matrix::UnresolvedSelector>] resolved_ignore_selectors
# File lib/pact_broker/matrix/selector_ignorer.rb, line 19 def initialize(resolved_ignore_selectors) @resolved_ignore_selectors = resolved_ignore_selectors end
Public Instance Methods
ignore_pacticipant?(pacticipant)
click to toggle source
Whether the pacticipant should be ignored if the verification results are missing/failed. @param [PactBroker::Domain::Pacticipant] pacticipant @return [Boolean]
# File lib/pact_broker/matrix/selector_ignorer.rb, line 26 def ignore_pacticipant?(pacticipant) resolved_ignore_selectors.any? do | s | s.pacticipant_id == pacticipant.id && s.only_pacticipant_name_specified? end end
ignore_pacticipant_version?(pacticipant, version)
click to toggle source
Whether the pacticipant version should be ignored if the verification results are missing/failed. @param [PactBroker::Domain::Pacticipant] pacticipant @param [PactBroker::Domain::Version] version @return [Boolean]
# File lib/pact_broker/matrix/selector_ignorer.rb, line 36 def ignore_pacticipant_version?(pacticipant, version) resolved_ignore_selectors.any? do | s | s.pacticipant_id == pacticipant.id && (s.only_pacticipant_name_specified? || s.pacticipant_version_id == version.id) end end