• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

api-platform / core / 25668346367
27%
master: 37%

Build:
Build:
LAST BUILD BRANCH: fix/property-info-service-not-required
DEFAULT BRANCH: master
Ran 11 May 2026 11:53AM UTC
Jobs 5
Files 1522
Run time 4min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

11 May 2026 11:50AM UTC coverage: 26.549% (-2.1%) from 28.663%
25668346367

push

github

web-flow
fix(hydra): emit hydra:next and hydra:previous on empty cursor-paginated collections (#7961)

* fix(hydra): emit hydra:next and hydra:previous on empty cursor-paginated collections

When a cursor-paginated collection returns no items and the request URL
already contains a cursor filter (e.g. id[gt]=10), navigation links were
silently omitted because populateDataWithCursorBasedPagination() relies on
reading the first and last objects of the collection.

Synthesize the links from the URL parameters instead:
- hydra:next: invert the cursor operator (gt -> lt), keep the value
- hydra:previous: keep the operator, shift the value by items_per_page

If no cursor filter is present in the URL, the behavior is unchanged.

Fixes #7953

Signed-off-by: Guillaume Delré <delre.guillaume@gmail.com>

* test(hydra): add cursor pagination empty collection regression test

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Tickets       | refs #7953
| License       | MIT
| Doc PR        | ∅

Adds CursorPaginatedDummy fixture (canonical QueryParameter form with
ComparisonFilter + SortFilter) and a phpunit functional test asserting
hydra:next / hydra:previous on empty cursor-paginated collections.

graphQlOperations is disabled on the fixture: a latent bug in
FieldsBuilder.php:515 (ServiceLocator::has called with a FilterInterface
instance instead of a service id) crashes the GraphQL schema build when
an object-form filter is combined with a bracketed parameter key.

---------

Signed-off-by: Guillaume Delré <delre.guillaume@gmail.com>
Co-authored-by: soyuka <soyuka@users.noreply.github.com>

23 of 73 new or added lines in 2 files covered. (31.51%)

16976 of 63942 relevant lines covered (26.55%)

78.82 hits per line

Uncovered Changes

Lines Coverage ∆ File
45
0.0
0.0% src/Hydra/Tests/Serializer/PartialCollectionViewNormalizerTest.php
5
78.65
16.36% src/Hydra/Serializer/PartialCollectionViewNormalizer.php
Jobs
ID Job ID Ran Files Coverage
1 25668346367.1 11 May 2026 11:53AM UTC 1521
25.76
GitHub Action Run
2 25668346367.2 11 May 2026 11:53AM UTC 1521
25.35
GitHub Action Run
3 25668346367.3 11 May 2026 11:55AM UTC 1491
0.0
GitHub Action Run
4 25668346367.4 11 May 2026 11:56AM UTC 1491
18.19
GitHub Action Run
5 25668346367.5 11 May 2026 11:57AM UTC 1491
13.81
GitHub Action Run
Source Files on build 25668346367
  • Tree
  • List 1522
  • Changed 101
  • Source Changed 0
  • Coverage Changed 101
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • f88b9122 on github
  • Prev Build on 4.3 (#25662376871)
  • Next Build on 4.3 (#25727713442)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc