v3: add active and private filter to owner query
This commit is contained in:
parent
140efa4766
commit
2b12aadc0d
|
@ -1,5 +1,7 @@
|
||||||
module Travis::API::V3
|
module Travis::API::V3
|
||||||
class Services::Owner::Find < Service
|
class Services::Owner::Find < Service
|
||||||
|
params :active, :private, prefix: :repository
|
||||||
|
|
||||||
def result_type
|
def result_type
|
||||||
@result_type ||= super
|
@result_type ||= super
|
||||||
end
|
end
|
||||||
|
|
|
@ -97,9 +97,9 @@ describe Travis::API::V3::ServiceIndex do
|
||||||
|
|
||||||
describe "find action" do
|
describe "find action" do
|
||||||
let(:action) { resource.fetch("actions").fetch("find") }
|
let(:action) { resource.fetch("actions").fetch("find") }
|
||||||
specify { expect(action).to include("@type"=>"template", "request_method"=>"GET", "uri_template"=>"#{path}owner/{owner.login}{?include}") }
|
specify { expect(action).to include("@type"=>"template", "request_method"=>"GET", "uri_template"=>"#{path}owner/{owner.login}{?active,include,private,repository.active,repository.private}") }
|
||||||
specify { expect(action).to include("@type"=>"template", "request_method"=>"GET", "uri_template"=>"#{path}owner/{user.login}{?include}") }
|
specify { expect(action).to include("@type"=>"template", "request_method"=>"GET", "uri_template"=>"#{path}owner/{user.login}{?active,include,private,repository.active,repository.private}") }
|
||||||
specify { expect(action).to include("@type"=>"template", "request_method"=>"GET", "uri_template"=>"#{path}owner/{organization.login}{?include}") }
|
specify { expect(action).to include("@type"=>"template", "request_method"=>"GET", "uri_template"=>"#{path}owner/{organization.login}{?active,include,private,repository.active,repository.private}") }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user