Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

give cursor TCK tests a meaningful page number rather than defaulting to 1 #678

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -941,7 +941,7 @@ public void testCursoredPageOf7FromCursor() {
// ^^^^^ next page ^^^^

Order<NaturalNumber> order = Order.by(Sort.asc("floorOfSquareRoot"), Sort.desc("id"));
PageRequest middle7 = PageRequest.ofSize(7)
PageRequest middle7 = PageRequest.ofPage(4).size(7)
.afterKey((short) 5, 5L, 26L); // 20th result is 26; it requires 5 bits and its square root rounds down to 5.

CursoredPage<NaturalNumber> page;
Expand Down Expand Up @@ -1047,7 +1047,7 @@ public void testCursoredPageWithoutTotalOf9FromCursor() {
// ^^^^^^^^ slice 2 ^^^^^^^^^
// ^^^^^^^^ slice 3 ^^^^^^^^^

PageRequest middle9 = PageRequest.ofSize(9).withoutTotal()
PageRequest middle9 = PageRequest.ofPage(4).size(9).withoutTotal()
.afterKey(6L, 46L); // 20th result is 46; its square root rounds down to 6.
Order<NaturalNumber> order = Order.by(Sort.desc("floorOfSquareRoot"), Sort.asc("id"));

Expand Down