Skip to content

Commit 5bad727

Browse files
authored
Merge pull request #17 from retailcrm/sensio-support-remove
Removed support of sensio/framework-extra-bundle
2 parents b72dfea + 45d1ed1 commit 5bad727

File tree

9 files changed

+5
-103
lines changed

9 files changed

+5
-103
lines changed

Extractor/Handler/SensioFrameworkExtraHandler.php

-32
This file was deleted.

Resources/config/services.xml

-5
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
<parameter key="nelmio_api_doc.extractor.handler.fos_rest.class">Nelmio\ApiDocBundle\Extractor\Handler\FosRestHandler</parameter>
1313
<parameter key="nelmio_api_doc.extractor.handler.jms_security.class">Nelmio\ApiDocBundle\Extractor\Handler\JmsSecurityExtraHandler</parameter>
14-
<parameter key="nelmio_api_doc.extractor.handler.sensio_framework_extra.class">Nelmio\ApiDocBundle\Extractor\Handler\SensioFrameworkExtraHandler</parameter>
1514
<parameter key="nelmio_api_doc.extractor.handler.phpdoc.class">Nelmio\ApiDocBundle\Extractor\Handler\PhpDocHandler</parameter>
1615

1716
<parameter key="nelmio_api_doc.parser.collection_parser.class">Nelmio\ApiDocBundle\Parser\CollectionParser</parameter>
@@ -53,10 +52,6 @@
5352
<tag name="nelmio_api_doc.extractor.handler"/>
5453
</service>
5554

56-
<service id="nelmio_api_doc.extractor.handler.sensio_framework_extra" class="%nelmio_api_doc.extractor.handler.sensio_framework_extra.class%" public="false">
57-
<tag name="nelmio_api_doc.extractor.handler"/>
58-
</service>
59-
6055
<service id="nelmio_api_doc.extractor.handler.phpdoc" class="%nelmio_api_doc.extractor.handler.phpdoc.class%" public="false">
6156
<argument type="service" id="nelmio_api_doc.doc_comment_extractor" />
6257
<tag name="nelmio_api_doc.extractor.handler"/>

Resources/doc/other-bundle-annotations.rst

-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ This bundle will get information from the following other annotations:
88
(when strict parameter is true), ``filters`` (when strict is false)
99
* ``@JMS\SecurityExtraBundle\Annotation\Secure`` - set ``authentication`` to true,
1010
``authenticationRoles`` to the given roles
11-
* ``@Sensio\Bundle\FrameworkExtraBundle\Configuration\Cache`` - set ``cache``
1211

1312
PHPDoc
1413
------

Tests/Extractor/ApiDocExtractorTest.php

-13
Original file line numberDiff line numberDiff line change
@@ -224,19 +224,6 @@ public function testGetWithAuthentication()
224224
$this->assertCount(2, $annotation->getAuthenticationRoles());
225225
}
226226

227-
public function testGetWithCache()
228-
{
229-
$container = $this->getContainer();
230-
$extractor = $container->get('nelmio_api_doc.extractor.api_doc_extractor');
231-
$annotation = $extractor->get('Nelmio\ApiDocBundle\Tests\Fixtures\Controller\TestController::zCachedAction', 'test_route_23');
232-
233-
$this->assertNotNull($annotation);
234-
$this->assertEquals(
235-
60,
236-
$annotation->getCache()
237-
);
238-
}
239-
240227
public function testGetWithDeprecated()
241228
{
242229
$container = $this->getContainer();

Tests/Extractor/Handler/SensioFrameworkExtraHandlerTest.php

-39
This file was deleted.

Tests/Fixtures/Controller/TestController.php

-6
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,8 @@
1515
use FOS\RestBundle\Controller\Annotations\RequestParam;
1616
use Nelmio\ApiDocBundle\Annotation\ApiDoc;
1717
use Nelmio\ApiDocBundle\Tests\Fixtures\DependencyTypePath;
18-
use Nelmio\ApiDocBundle\Tests\Fixtures\RequestParamHelper;
19-
use Nelmio\ApiDocBundle\Util\LegacyFormHelper;
2018
use Symfony\Component\HttpFoundation\Response;
2119
use Symfony\Component\Validator\Constraints as Assert;
22-
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Cache;
23-
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Security;
2420

2521
class TestController
2622
{
@@ -219,15 +215,13 @@ public function authenticatedAction()
219215

220216
/**
221217
* @ApiDoc()
222-
* @Cache(maxage=60, public=1)
223218
*/
224219
public function zCachedAction()
225220
{
226221
}
227222

228223
/**
229224
* @ApiDoc()
230-
* @Security("has_role('ROLE_USER')")
231225
*/
232226
public function zSecuredAction()
233227
{

Tests/Formatter/testFormat-result.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -2605,7 +2605,6 @@
26052605
array (
26062606
'method' => 'POST',
26072607
'uri' => '/zcached',
2608-
'cache' => 60,
26092608
'https' => false,
26102609
'authentication' => false,
26112610
'authenticationRoles' =>
@@ -2618,7 +2617,7 @@
26182617
'method' => 'POST',
26192618
'uri' => '/zsecured',
26202619
'https' => false,
2621-
'authentication' => true,
2620+
'authentication' => false,
26222621
'authenticationRoles' =>
26232622
array (
26242623
),

Tests/Formatter/testFormat-result_1.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -2448,7 +2448,6 @@
24482448
array (
24492449
'method' => 'POST',
24502450
'uri' => '/zcached',
2451-
'cache' => 60,
24522451
'https' => false,
24532452
'authentication' => false,
24542453
'authenticationRoles' =>
@@ -2461,7 +2460,7 @@
24612460
'method' => 'POST',
24622461
'uri' => '/zsecured',
24632462
'https' => false,
2464-
'authentication' => true,
2463+
'authentication' => false,
24652464
'authenticationRoles' =>
24662465
array (
24672466
),

composer.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@
2323
"michelf/php-markdown": "~1.4"
2424
},
2525
"require-dev": {
26+
"doctrine/annotations": "^1.0",
2627
"friendsofsymfony/rest-bundle": "^3.7",
27-
"jms/serializer": "~3.15.0",
28-
"jms/serializer-bundle": "4.1.0",
28+
"jms/serializer": "^3.15",
29+
"jms/serializer-bundle": "^4.1|^5.4",
2930
"phpunit/phpunit": "~9.5",
30-
"sensio/framework-extra-bundle": "^6.2",
3131
"symfony/asset": "^5.0|^6.0",
3232
"symfony/browser-kit": "^5.0|^6.0",
3333
"symfony/translation": "^5.0|^6.0",

0 commit comments

Comments
 (0)