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

api-platform / core / 26958513110

04 Jun 2026 02:33PM UTC coverage: 29.776% (+0.8%) from 28.969%
26958513110

push

github

soyuka
test(hal): inject resourceMetadataFactory in SchemaFactoryTest

Hal SchemaFactory ctor takes (schemaFactory, definitionNameFactory,
resourceMetadataFactory). setUp() omitted the third argument, so
Hal's ResourceMetadataTrait::isResourceClass(Dummy) returned false,
causing Hal to bypass its own wrap and delegate straight to the base
factory with format='jsonhal'. The base factory then wrote
Dummy.jsonhal={type:object}, never producing the allOf wrap the
tests assert on.

Hal was added to the CI matrix in 49c622b1a, exposing this for the
first time. Pass the existing $resourceMetadataFactory mock so
isResourceClass() resolves true and the wrap fires.

0 of 1 new or added line in 1 file covered. (0.0%)

9 existing lines in 1 file now uncovered.

19329 of 64915 relevant lines covered (29.78%)

158.73 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/Hal/Tests/JsonSchema/SchemaFactoryTest.php


Source Not Available

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