mirror of
https://github.com/retailcrm/NelmioApiDocBundle.git
synced 2025-03-12 18:46:10 +03:00
Fix a wrong use of operation->security (#1700)
This commit is contained in:
parent
eeb4a8b90e
commit
282724580c
@ -26,8 +26,6 @@ final class RouteMetadataDescriber implements RouteDescriberInterface
|
|||||||
public function describe(OA\OpenApi $api, Route $route, \ReflectionMethod $reflectionMethod)
|
public function describe(OA\OpenApi $api, Route $route, \ReflectionMethod $reflectionMethod)
|
||||||
{
|
{
|
||||||
foreach ($this->getOperations($api, $route) as $operation) {
|
foreach ($this->getOperations($api, $route) as $operation) {
|
||||||
Util::merge($operation, ['security' => $route->getSchemes()]);
|
|
||||||
|
|
||||||
$requirements = $route->getRequirements();
|
$requirements = $route->getRequirements();
|
||||||
$compiledRoute = $route->compile();
|
$compiledRoute = $route->compile();
|
||||||
$existingParams = $this->getRefParams($api, $operation);
|
$existingParams = $this->getRefParams($api, $operation);
|
||||||
|
@ -110,7 +110,7 @@ class FunctionalTest extends WebTestCase
|
|||||||
{
|
{
|
||||||
$operation = $this->getOperation('/api/test/{user}', 'get');
|
$operation = $this->getOperation('/api/test/{user}', 'get');
|
||||||
|
|
||||||
$this->assertEquals(['https'], $operation->security);
|
$this->assertEquals(OA\UNDEFINED, $operation->security);
|
||||||
$this->assertEquals(OA\UNDEFINED, $operation->summary);
|
$this->assertEquals(OA\UNDEFINED, $operation->summary);
|
||||||
$this->assertEquals(OA\UNDEFINED, $operation->description);
|
$this->assertEquals(OA\UNDEFINED, $operation->description);
|
||||||
$this->assertEquals(OA\UNDEFINED, $operation->deprecated);
|
$this->assertEquals(OA\UNDEFINED, $operation->deprecated);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user