You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Move the 4.4 Operation::$filters deprecation out of OpenApiFactory into
FiltersResourceMetadataCollectionFactory so it fires once at metadata
build for every consumer, not only during OpenAPI generation; rebuild
the deprecation baseline accordingly.
Move DummyExceptionToStatus to Entity/Legacy/ with #[ApiFilter] instead
of the QueryParameter form, which routed missing-required-param
validation through the 422 constraint path (#8211) and broke the
exceptionToStatus 400/404 contract the test guards.
Bump the OpenApiTest foobar[] parameter index and extend the
PropertyFilter OpenAPI example with the nested-property form.
trigger_deprecation('api-platform/core', '4.4', \sprintf('Declaring filters on the "%s" operation through "Operation::$filters" is deprecated, use the "parameters" argument instead. It will be removed in 6.0.', $operation->getShortName()));
trigger_deprecation('api-platform/core', '4.4', \sprintf('Declaring filters on the "%s" operation through "Operation::$filters" is deprecated, use the "%s" attribute instead. It will be removed in 6.0.', $operation->getShortName(), QueryParameter::class));
708
-
}
709
-
710
-
// Collapse identical filter deprecations to one warning per (filter, shortName) per
711
-
// generation: a filter exposing N parameters must not emit the same message N times.
if (isset($description['swagger']) && !isset($warned[$warnKey]['swagger'])) {
723
+
if (isset($description['swagger'])) {
735
724
trigger_deprecation('api-platform/core', '4.0', \sprintf('Using the "swagger" field of the %s::getDescription() (%s) is deprecated.', $filter, $shortName));
736
-
$warned[$warnKey]['swagger'] = true;
737
725
}
738
726
739
727
if (!isset($description['openapi']) || $description['openapi'] instanceof Parameter) {
trigger_deprecation('api-platform/core', '4.0', \sprintf('Not using "%s" on the "openapi" field of the %s::getDescription() (%s) is deprecated.', Parameter::class, $filter, $shortName));
787
-
$warned[$warnKey]['openapi'] = true;
788
-
}
773
+
trigger_deprecation('api-platform/core', '4.0', \sprintf('Not using "%s" on the "openapi" field of the %s::getDescription() (%s) is deprecated.', Parameter::class, $filter, $shortName));
$this->assertSame('Allows you to reduce the response to contain only the properties you need. If your desired property is nested, you can address it using nested arrays. Example: foobar[]={propertyName}&foobar[]={anotherPropertyName}&foobar[{nestedPropertyParent}][]={nestedProperty}', $json['paths']['/dummy_cars']['get']['parameters'][9]['description']);
$this->assertSame('Allows you to reduce the response to contain only the properties you need. If your desired property is nested, you can address it using nested arrays. Example: foobar[]={propertyName}&foobar[]={anotherPropertyName}&foobar[{nestedPropertyParent}][]={nestedProperty}', $json['paths']['/dummy_cars']['get']['parameters'][10]['description']);
429
429
430
430
// Webhook
431
431
$this->assertSame('Something else here for example', $json['webhooks']['a/{id}']['get']['description']);
0 commit comments