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

Allow use with Pagerfanta 3.0 #298

Merged
merged 6 commits into from
Nov 5, 2021

Conversation

mbabker
Copy link
Contributor

@mbabker mbabker commented Mar 19, 2021

Q A
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Related tickets N/A
License MIT

Pagerfanta and PagerfantaBundle both have stable 3.0 tags now, this PR adds support for the new major version.

@mbabker mbabker requested a review from a team as a code owner March 19, 2021 15:33
Copy link
Member

@lchrusciel lchrusciel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't we just migrate to 3.0 only?

@mbabker
Copy link
Contributor Author

mbabker commented Mar 23, 2021 via email

@mbabker
Copy link
Contributor Author

mbabker commented Nov 3, 2021

I plan on EOL'ing the 2.x branch of the PagerfantaBundle at the end of this year, and the Pagerfanta library's 2.x branch won't get much support in 2022. So, moving forward with this and Sylius/SyliusGridBundle#143 would be really helpful in keeping Sylius from being locked to non-supported software branches (which also means Sylius/Sylius#12462 needs some focus to be able to fully complete the upgrade).

@lchrusciel
Copy link
Member

Therefore, let's just migrate to 3.0

@mbabker
Copy link
Contributor Author

mbabker commented Nov 3, 2021

Therefore, let's just migrate to 3.0

Done

@loic425 loic425 mentioned this pull request Nov 5, 2021
@@ -76,7 +76,7 @@ function it_handles_Pagerfanta(

$paginator->setMaxPerPage(5)->shouldBeCalled();
$paginator->setCurrentPage(6)->shouldBeCalled();
$paginator->getCurrentPageResults()->shouldBeCalled();
$paginator->getCurrentPageResults()->willReturn([]);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why did you change this line?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I originally did this the tests failed because of the lack of a return, most of the Pagerfanta package has return types declared in the 3.x branch.

@lchrusciel lchrusciel merged commit 50bc7f9 into Sylius:master Nov 5, 2021
@lchrusciel
Copy link
Member

Thanks, Michael! 🥇

@lchrusciel
Copy link
Member

It was a long run, but it finally landed in the codebase! :D 🎉

@mbabker mbabker deleted the feature/pagerfanta-3 branch November 5, 2021 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants