Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit e2ac5df

Browse filesBrowse files
committed
Merge branch '2.3' into 2.4
* 2.3: fixed various inconsistencies reduced recursion when building DumperPrefixCollection renamed variables - making next change more readable removing dead code. [DomCrawler] Fixed filterXPath() chaining [DomCrawler] Fixed incorrect handling of image inputs Conflicts: src/Symfony/Component/DomCrawler/Crawler.php src/Symfony/Component/EventDispatcher/Tests/EventDispatcherTest.php src/Symfony/Component/Form/Extension/DependencyInjection/DependencyInjectionExtension.php src/Symfony/Component/Serializer/Tests/Normalizer/CustomNormalizerTest.php src/Symfony/Component/Templating/Tests/Loader/CacheLoaderTest.php src/Symfony/Component/Templating/Tests/Loader/LoaderTest.php
2 parents 4ab78e0 + a1813cb commit e2ac5df
Copy full SHA for e2ac5df

File tree

Expand file treeCollapse file tree

53 files changed

+126
-131
lines changed
Filter options

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree

53 files changed

+126
-131
lines changed

‎src/Symfony/Bridge/Doctrine/Security/User/EntityUserProvider.php

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Doctrine/Security/User/EntityUserProvider.php
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,8 @@ public function refreshUser(UserInterface $user)
9292
);
9393
}
9494

95-
if (null === $refreshedUser = $this->repository->find($id)) {
95+
$refreshedUser = $this->repository->find($id);
96+
if (null === $refreshedUser) {
9697
throw new UsernameNotFoundException(sprintf('User with id %s not found', json_encode($id)));
9798
}
9899
}

‎src/Symfony/Bridge/Doctrine/Tests/Fixtures/AssociationEntity.php

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Doctrine/Tests/Fixtures/AssociationEntity.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
namespace Symfony\Bridge\Doctrine\Tests\Fixtures;
1313

14-
use Doctrine\ORM\Mapping AS ORM;
14+
use Doctrine\ORM\Mapping as ORM;
1515

1616
/**
1717
* @ORM\Entity

‎src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Compiler/CompilerDebugDumpPass.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Compiler/CompilerDebugDumpPass.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public function process(ContainerBuilder $container)
2222
{
2323
$filesystem = new Filesystem();
2424
$filesystem->dumpFile(
25-
$this->getCompilerLogFilename($container),
25+
self::getCompilerLogFilename($container),
2626
implode("\n", $container->getCompiler()->getLog()),
2727
0666 & ~umask()
2828
);

‎src/Symfony/Bundle/FrameworkBundle/Tests/CacheWarmer/TemplateFinderTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/Tests/CacheWarmer/TemplateFinderTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function testFindAllTemplates()
3737
->will($this->returnValue(array('BaseBundle' => new BaseBundle())))
3838
;
3939

40-
$parser = new TemplateFilenameParser($kernel);
40+
$parser = new TemplateFilenameParser();
4141

4242
$finder = new TemplateFinder($kernel, $parser, __DIR__.'/../Fixtures/Resources');
4343

‎src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/ConfigurationTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/ConfigurationTest.php
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ public function testDefaultConfig()
3333
public function testValidTrustedProxies($trustedProxies, $processedProxies)
3434
{
3535
$processor = new Processor();
36-
$configuration = new Configuration(array());
36+
$configuration = new Configuration();
3737
$config = $processor->processConfiguration($configuration, array(array(
3838
'secret' => 's3cr3t',
3939
'trusted_proxies' => $trustedProxies
@@ -62,7 +62,7 @@ public function getTestValidTrustedProxiesData()
6262
public function testInvalidTypeTrustedProxies()
6363
{
6464
$processor = new Processor();
65-
$configuration = new Configuration(array());
65+
$configuration = new Configuration();
6666
$processor->processConfiguration($configuration, array(
6767
array(
6868
'secret' => 's3cr3t',
@@ -77,7 +77,7 @@ public function testInvalidTypeTrustedProxies()
7777
public function testInvalidValueTrustedProxies()
7878
{
7979
$processor = new Processor();
80-
$configuration = new Configuration(array());
80+
$configuration = new Configuration();
8181
$processor->processConfiguration($configuration, array(
8282
array(
8383
'secret' => 's3cr3t',

‎src/Symfony/Bundle/FrameworkBundle/Tests/Functional/WebTestCase.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/Tests/Functional/WebTestCase.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ protected static function getKernelClass()
3737
{
3838
require_once __DIR__.'/app/AppKernel.php';
3939

40-
return 'Symfony\Bundle\FrameworkBundle\Tests\Functional\AppKernel';
40+
return 'Symfony\Bundle\FrameworkBundle\Tests\Functional\app\AppKernel';
4141
}
4242

4343
protected static function createKernel(array $options = array())

‎src/Symfony/Bundle/FrameworkBundle/Tests/Functional/app/AppKernel.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/Tests/Functional/app/AppKernel.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* file that was distributed with this source code.
1010
*/
1111

12-
namespace Symfony\Bundle\FrameworkBundle\Tests\Functional;
12+
namespace Symfony\Bundle\FrameworkBundle\Tests\Functional\app;
1313

1414
// get the autoload file
1515
$dir = __DIR__;

‎src/Symfony/Bundle/SecurityBundle/Tests/Functional/WebTestCase.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/SecurityBundle/Tests/Functional/WebTestCase.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ protected static function getKernelClass()
3737
{
3838
require_once __DIR__.'/app/AppKernel.php';
3939

40-
return 'Symfony\Bundle\SecurityBundle\Tests\Functional\AppKernel';
40+
return 'Symfony\Bundle\SecurityBundle\Tests\Functional\app\AppKernel';
4141
}
4242

4343
protected static function createKernel(array $options = array())

‎src/Symfony/Bundle/SecurityBundle/Tests/Functional/app/AppKernel.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/SecurityBundle/Tests/Functional/app/AppKernel.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* file that was distributed with this source code.
1010
*/
1111

12-
namespace Symfony\Bundle\SecurityBundle\Tests\Functional;
12+
namespace Symfony\Bundle\SecurityBundle\Tests\Functional\app;
1313

1414
// get the autoload file
1515
$dir = __DIR__;

‎src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/ConfigurationTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/ConfigurationTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
2222
public function testConfigTree($options, $results)
2323
{
2424
$processor = new Processor();
25-
$configuration = new Configuration(array());
25+
$configuration = new Configuration();
2626
$config = $processor->processConfiguration($configuration, array($options));
2727

2828
$this->assertEquals($results, $config);

‎src/Symfony/Component/ClassLoader/XcacheClassLoader.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/ClassLoader/XcacheClassLoader.php
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,8 @@ public function findFile($class)
116116
if (xcache_isset($this->prefix.$class)) {
117117
$file = xcache_get($this->prefix.$class);
118118
} else {
119-
xcache_set($this->prefix.$class, $file = $this->classFinder->findFile($class));
119+
$file = $this->classFinder->findFile($class);
120+
xcache_set($this->prefix.$class, $file);
120121
}
121122

122123
return $file;

‎src/Symfony/Component/Console/Helper/ProgressHelper.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Console/Helper/ProgressHelper.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ private function generate($finish = false)
349349
$vars = array();
350350
$percent = 0;
351351
if ($this->max > 0) {
352-
$percent = (double) $this->current / $this->max;
352+
$percent = (float) $this->current / $this->max;
353353
}
354354

355355
if (isset($this->formatVars['bar'])) {

‎src/Symfony/Component/Console/Tests/ApplicationTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Console/Tests/ApplicationTest.php
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@ public function testSetCatchExceptions()
471471
public function testAsText()
472472
{
473473
$application = new Application();
474-
$application->add(new \FooCommand);
474+
$application->add(new \FooCommand());
475475
$this->ensureStaticCommandHelp($application);
476476
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext1.txt', $this->normalizeLineBreaks($application->asText()), '->asText() returns a text representation of the application');
477477
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext2.txt', $this->normalizeLineBreaks($application->asText('foo')), '->asText() returns a text representation of the application');
@@ -480,7 +480,7 @@ public function testAsText()
480480
public function testAsXml()
481481
{
482482
$application = new Application();
483-
$application->add(new \FooCommand);
483+
$application->add(new \FooCommand());
484484
$this->ensureStaticCommandHelp($application);
485485
$this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/application_asxml1.txt', $application->asXml(), '->asXml() returns an XML representation of the application');
486486
$this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/application_asxml2.txt', $application->asXml('foo'), '->asXml() returns an XML representation of the application');
@@ -504,7 +504,7 @@ public function testRenderException()
504504
$tester->run(array('command' => 'list', '--foo' => true), array('decorated' => false));
505505
$this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception2.txt', $tester->getDisplay(true), '->renderException() renders the command synopsis when an exception occurs in the context of a command');
506506

507-
$application->add(new \Foo3Command);
507+
$application->add(new \Foo3Command());
508508
$tester = new ApplicationTester($application);
509509
$tester->run(array('command' => 'foo3:bar'), array('decorated' => false));
510510
$this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception3.txt', $tester->getDisplay(true), '->renderException() renders a pretty exceptions with previous exceptions');

‎src/Symfony/Component/CssSelector/Tests/Parser/Handler/NumberHandlerTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/CssSelector/Tests/Parser/Handler/NumberHandlerTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Component\CssSelector\Parser\Handler\NumberHandler;
1515
use Symfony\Component\CssSelector\Parser\Token;
1616
use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerPatterns;
17-
use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerEscaping;
1817

1918
class NumberHandlerTest extends AbstractHandlerTest
2019
{
@@ -46,6 +45,6 @@ protected function generateHandler()
4645
{
4746
$patterns = new TokenizerPatterns();
4847

49-
return new NumberHandler($patterns, new TokenizerEscaping($patterns));
48+
return new NumberHandler($patterns);
5049
}
5150
}

‎src/Symfony/Component/Debug/Tests/ExceptionHandlerTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Debug/Tests/ExceptionHandlerTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,6 @@ public function testHeaders()
5757
public function testNestedExceptions()
5858
{
5959
$handler = new ExceptionHandler(true);
60-
$response = $handler->createResponse(new \RuntimeException('Foo', null, new \RuntimeException('Bar')));
60+
$response = $handler->createResponse(new \RuntimeException('Foo', 0, new \RuntimeException('Bar')));
6161
}
6262
}

‎src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ public function __construct(ContainerBuilder $container)
6969
{
7070
parent::__construct($container);
7171

72-
$this->inlinedDefinitions = new \SplObjectStorage;
72+
$this->inlinedDefinitions = new \SplObjectStorage();
7373
}
7474

7575
/**

‎src/Symfony/Component/DomCrawler/Crawler.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DomCrawler/Crawler.php
+6-8Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ public function parents()
454454
$nodes = array();
455455

456456
while ($node = $node->parentNode) {
457-
if (1 === $node->nodeType && '_root' !== $node->nodeName) {
457+
if (1 === $node->nodeType) {
458458
$nodes[] = $node;
459459
}
460460
}
@@ -599,16 +599,14 @@ public function extract($attributes)
599599
*/
600600
public function filterXPath($xpath)
601601
{
602-
$document = new \DOMDocument('1.0', 'UTF-8');
603-
$root = $document->appendChild($document->createElement('_root'));
602+
$crawler = new static(null, $this->uri);
603+
$prefixes = $this->findNamespacePrefixes($xpath);
604604
foreach ($this as $node) {
605-
$root->appendChild($document->importNode($node, true));
605+
$domxpath = $this->createDOMXPath($node->ownerDocument, $prefixes);
606+
$crawler->add($domxpath->query($xpath, $node));
606607
}
607608

608-
$prefixes = $this->findNamespacePrefixes($xpath);
609-
$domxpath = $this->createDOMXPath($document, $prefixes);
610-
611-
return new static($domxpath->query($xpath), $this->uri);
609+
return $crawler;
612610
}
613611

614612
/**

‎src/Symfony/Component/DomCrawler/Field/FormField.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DomCrawler/Field/FormField.php
+1-7Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,7 @@ public function __construct(\DOMNode $node)
5252
{
5353
$this->node = $node;
5454
$this->name = $node->getAttribute('name');
55-
56-
$this->document = new \DOMDocument('1.0', 'UTF-8');
57-
$this->node = $this->document->importNode($this->node, true);
58-
59-
$root = $this->document->appendChild($this->document->createElement('_root'));
60-
$root->appendChild($this->node);
61-
$this->xpath = new \DOMXPath($this->document);
55+
$this->xpath = new \DOMXPath($node->ownerDocument);
6256

6357
$this->initialize();
6458
}

‎src/Symfony/Component/DomCrawler/Form.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DomCrawler/Form.php
+24-15Lines changed: 24 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -394,34 +394,43 @@ private function initialize()
394394
{
395395
$this->fields = new FormFieldRegistry();
396396

397-
$document = new \DOMDocument('1.0', 'UTF-8');
398-
$xpath = new \DOMXPath($document);
399-
$root = $document->appendChild($document->createElement('_root'));
397+
$xpath = new \DOMXPath($this->node->ownerDocument);
400398

401399
// add submitted button if it has a valid name
402400
if ('form' !== $this->button->nodeName && $this->button->hasAttribute('name') && $this->button->getAttribute('name')) {
403-
$this->set(new Field\InputFormField($document->importNode($this->button, true)));
401+
if ('input' == $this->button->nodeName && 'image' == $this->button->getAttribute('type')) {
402+
$name = $this->button->getAttribute('name');
403+
$this->button->setAttribute('value', '0');
404+
405+
// temporarily change the name of the input node for the x coordinate
406+
$this->button->setAttribute('name', $name.'.x');
407+
$this->set(new Field\InputFormField($this->button));
408+
409+
// temporarily change the name of the input node for the y coordinate
410+
$this->button->setAttribute('name', $name.'.y');
411+
$this->set(new Field\InputFormField($this->button));
412+
413+
// restore the original name of the input node
414+
$this->button->setAttribute('name', $name);
415+
} else {
416+
$this->set(new Field\InputFormField($this->button));
417+
}
404418
}
405419

406420
// find form elements corresponding to the current form
407421
if ($this->node->hasAttribute('id')) {
408-
// traverse through the whole document
409-
$node = $document->importNode($this->node->ownerDocument->documentElement, true);
410-
$root->appendChild($node);
411-
412422
// corresponding elements are either descendants or have a matching HTML5 form attribute
413423
$formId = Crawler::xpathLiteral($this->node->getAttribute('id'));
414-
$fieldNodes = $xpath->query(sprintf('descendant::input[@form=%s] | descendant::button[@form=%s] | descendant::textarea[@form=%s] | descendant::select[@form=%s] | //form[@id=%s]//input[not(@form)] | //form[@id=%s]//button[not(@form)] | //form[@id=%s]//textarea[not(@form)] | //form[@id=%s]//select[not(@form)]', $formId, $formId, $formId, $formId, $formId, $formId, $formId, $formId), $root);
424+
425+
// do the xpath query without $this->node as the context node (i.e. traverse through the whole document)
426+
$fieldNodes = $xpath->query(sprintf('descendant::input[@form=%s] | descendant::button[@form=%s] | descendant::textarea[@form=%s] | descendant::select[@form=%s] | //form[@id=%s]//input[not(@form)] | //form[@id=%s]//button[not(@form)] | //form[@id=%s]//textarea[not(@form)] | //form[@id=%s]//select[not(@form)]', $formId, $formId, $formId, $formId, $formId, $formId, $formId, $formId));
415427
foreach ($fieldNodes as $node) {
416428
$this->addField($node);
417429
}
418430
} else {
419-
// parent form has no id, add descendant elements only
420-
$node = $document->importNode($this->node, true);
421-
$root->appendChild($node);
422-
423-
// descendant elements with form attribute are not part of this form
424-
$fieldNodes = $xpath->query('descendant::input[not(@form)] | descendant::button[not(@form)] | descendant::textarea[not(@form)] | descendant::select[not(@form)]', $root);
431+
// do the xpath query with $this->node as the context node, to only find descendant elements
432+
// however, descendant elements with form attribute are not part of this form
433+
$fieldNodes = $xpath->query('descendant::input[not(@form)] | descendant::button[not(@form)] | descendant::textarea[not(@form)] | descendant::select[not(@form)]', $this->node);
425434
foreach ($fieldNodes as $node) {
426435
$this->addField($node);
427436
}

‎src/Symfony/Component/DomCrawler/Tests/CrawlerTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DomCrawler/Tests/CrawlerTest.php
+3-1Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,8 +390,10 @@ public function testFilterXPath()
390390
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->filterXPath() returns a new instance of a crawler');
391391

392392
$crawler = $this->createTestCrawler()->filterXPath('//ul');
393-
394393
$this->assertCount(6, $crawler->filterXPath('//li'), '->filterXPath() filters the node list with the XPath expression');
394+
395+
$crawler = $this->createTestCrawler();
396+
$this->assertCount(3, $crawler->filterXPath('//body')->filterXPath('//button')->parents(), '->filterXpath() preserves parents when chained');
395397
}
396398

397399
public function testFilterXPathWithDefaultNamespace()

‎src/Symfony/Component/DomCrawler/Tests/FormTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DomCrawler/Tests/FormTest.php
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,11 @@ public function provideInitializeValues()
223223
<input type="submit" name="foobar" value="foobar" />',
224224
array('foobar' => array('InputFormField', 'foobar')),
225225
),
226+
array(
227+
'turns an image input into x and y fields',
228+
'<input type="image" name="bar" />',
229+
array('bar.x' => array('InputFormField', '0'), 'bar.y' => array('InputFormField', '0')),
230+
),
226231
array(
227232
'returns textareas',
228233
'<textarea name="foo">foo</textarea>

‎src/Symfony/Component/EventDispatcher/Tests/ContainerAwareEventDispatcherTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/EventDispatcher/Tests/ContainerAwareEventDispatcherTest.php
-6Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,6 @@ public function testHasListenersOnLazyLoad()
175175

176176
public function testGetListenersOnLazyLoad()
177177
{
178-
$event = new Event();
179-
180178
$service = $this->getMock('Symfony\Component\EventDispatcher\Tests\Service');
181179

182180
$container = new Container();
@@ -194,8 +192,6 @@ public function testGetListenersOnLazyLoad()
194192

195193
public function testRemoveAfterDispatch()
196194
{
197-
$event = new Event();
198-
199195
$service = $this->getMock('Symfony\Component\EventDispatcher\Tests\Service');
200196

201197
$container = new Container();
@@ -211,8 +207,6 @@ public function testRemoveAfterDispatch()
211207

212208
public function testRemoveBeforeDispatch()
213209
{
214-
$event = new Event();
215-
216210
$service = $this->getMock('Symfony\Component\EventDispatcher\Tests\Service');
217211

218212
$container = new Container();

‎src/Symfony/Component/EventDispatcher/Tests/EventDispatcherTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/EventDispatcher/Tests/EventDispatcherTest.php
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -240,6 +240,7 @@ public function testRemoveSubscriberWithMultipleListeners()
240240

241241
public function testEventReceivesTheDispatcherInstance()
242242
{
243+
$dispatcher = null;
243244
$this->dispatcher->addListener('test', function ($event) use (&$dispatcher) {
244245
$dispatcher = $event->getDispatcher();
245246
});

‎src/Symfony/Component/EventDispatcher/Tests/ImmutableEventDispatcherTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/EventDispatcher/Tests/ImmutableEventDispatcherTest.php
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use Symfony\Component\EventDispatcher\Event;
1515
use Symfony\Component\EventDispatcher\ImmutableEventDispatcher;
16-
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
1716

1817
/**
1918
* @author Bernhard Schussek <bschussek@gmail.com>

‎src/Symfony/Component/Form/Extension/DependencyInjection/DependencyInjectionExtension.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Extension/DependencyInjection/DependencyInjectionExtension.php
-5Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,10 @@
1919
class DependencyInjectionExtension implements FormExtensionInterface
2020
{
2121
private $container;
22-
2322
private $typeServiceIds;
24-
2523
private $typeExtensionServiceIds;
26-
2724
private $guesserServiceIds;
28-
2925
private $guesser;
30-
3126
private $guesserLoaded = false;
3227

3328
public function __construct(ContainerInterface $container,

‎src/Symfony/Component/Form/Test/FormPerformanceTestCase.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Test/FormPerformanceTestCase.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public function setMaxRunningTime($maxRunningTime)
5555
if (is_integer($maxRunningTime) && $maxRunningTime >= 0) {
5656
$this->maxRunningTime = $maxRunningTime;
5757
} else {
58-
throw new \InvalidArgumentException;
58+
throw new \InvalidArgumentException();
5959
}
6060
}
6161

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.