-
-
Notifications
You must be signed in to change notification settings - Fork 178
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* chore: add pagination to pacticipants * chore: Remove unused pagination options from versions resource * chore: Fix arguments in pacticipant service find method * chore: add missing dependencies to versions resource * chore: fix up argument parameters for pacticipant find method * chore: fix up argument parameters for pacticipant find method * chore: PR feedback refactors for pagination of pacticipants * chore: PR feedback remove request arg as it's already available
- Loading branch information
Showing
12 changed files
with
104 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
describe "Get pacticipants" do | ||
|
||
let(:path) { "/pacticipants" } | ||
let(:response_body_hash) { JSON.parse(subject.body, symbolize_names: true) } | ||
let(:expected_response_body) { {name: "Foo"} } | ||
|
||
subject { get(path) } | ||
|
||
context "when pacts exist" do | ||
|
||
before do | ||
td.create_pacticipant("Foo") | ||
.create_label("ios") | ||
.create_pacticipant("Bar") | ||
.create_label("android") | ||
end | ||
|
||
it "returns a 200 OK" do | ||
expect(subject).to be_a_hal_json_success_response | ||
end | ||
|
||
context "with pagination options" do | ||
subject { get(path, { "pageSize" => "1", "pageNumber" => "1" }) } | ||
|
||
it "paginates the response" do | ||
expect(response_body_hash[:_links][:"pacticipants"].size).to eq 1 | ||
end | ||
|
||
it "includes the pagination relations" do | ||
expect(response_body_hash[:_links]).to have_key(:next) | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters