7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# File 'lib/pact_broker/matrix/parse_can_i_deploy_query.rb', line 7
def self.call params
selector = PactBroker::Matrix::UnresolvedSelector.new
options = {
latestby: 'cvp',
latest: true
}
if params[:pacticipant].is_a?(String)
selector.pacticipant_name = params[:pacticipant]
end
if params[:version].is_a?(String)
selector.pacticipant_version_number = params[:version]
end
if params[:to].is_a?(String)
options[:tag] = params[:to]
end
return [selector], options
end
|