Skip to content

Commit f6d9110

Browse files
committed
Merge branch '2.3' into 2.7
* 2.3: Detect Mintty for color support on Windows Add a group for tests of the finder against the FTP server Fix license headers Forbid serializing a Crawler Fix phpdoc block of NativeSessionStorage class Added exception when setAutoInitialize is called when locked [FrameworkBundle] Advanced search templates of bundles [Security] Allow user providers to be defined in many files Use random_bytes function if it is available for random number generation
2 parents befb91e + 542c0a0 commit f6d9110

File tree

8 files changed

+43
-2
lines changed

8 files changed

+43
-2
lines changed

CacheWarmer/TemplateFinder.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,12 @@ private function findTemplatesInFolder($dir)
9797
*/
9898
private function findTemplatesInBundle(BundleInterface $bundle)
9999
{
100-
$templates = $this->findTemplatesInFolder($bundle->getPath().'/Resources/views');
101100
$name = $bundle->getName();
101+
$templates = array_merge(
102+
$this->findTemplatesInFolder($bundle->getPath().'/Resources/views'),
103+
$this->findTemplatesInFolder($this->rootDir.'/'.$name.'/views')
104+
);
105+
$templates = array_unique($templates);
102106

103107
foreach ($templates as $i => $template) {
104108
$templates[$i] = $template->set('bundle', $name);

Tests/CacheWarmer/TemplateFinderTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,11 @@ function ($template) { return $template->getLogicalName(); },
4646
$finder->findAllTemplates()
4747
);
4848

49-
$this->assertCount(6, $templates, '->findAllTemplates() find all templates in the bundles and global folders');
49+
$this->assertCount(7, $templates, '->findAllTemplates() find all templates in the bundles and global folders');
5050
$this->assertContains('BaseBundle::base.format.engine', $templates);
5151
$this->assertContains('BaseBundle::this.is.a.template.format.engine', $templates);
5252
$this->assertContains('BaseBundle:controller:base.format.engine', $templates);
53+
$this->assertContains('BaseBundle:controller:custom.format.engine', $templates);
5354
$this->assertContains('::this.is.a.template.format.engine', $templates);
5455
$this->assertContains('::resource.format.engine', $templates);
5556
}

Tests/Command/CacheClearCommand/CacheClearCommandTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<?php
22

3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <[email protected]>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
312
namespace Symfony\Bundle\FrameworkBundle\Tests\Command\CacheClearCommand;
413

514
use Symfony\Bundle\FrameworkBundle\Console\Application;

Tests/Fixtures/Resources/BaseBundle/views/base.format.engine

Whitespace-only changes.

Tests/Fixtures/Resources/BaseBundle/views/controller/custom.format.engine

Whitespace-only changes.

Tests/Functional/app/Fragment/bundles.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<?php
22

3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <[email protected]>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
312
use Symfony\Bundle\FrameworkBundle\Tests\Functional\Bundle\TestBundle\TestBundle;
413
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
514

Tests/Functional/app/Profiler/bundles.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<?php
22

3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <[email protected]>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
312
use Symfony\Bundle\FrameworkBundle\Tests\Functional\Bundle\TestBundle\TestBundle;
413
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
514

Tests/Functional/app/Session/bundles.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<?php
22

3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <[email protected]>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
312
use Symfony\Bundle\FrameworkBundle\Tests\Functional\Bundle\TestBundle\TestBundle;
413
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
514

0 commit comments

Comments
 (0)