8000 Merge branch '2.6' into 2.7 · symfony/symfony@38b9a88 · GitHub
[go: up one dir, main page]

Skip to content

Commit 38b9a88

Browse files
Merge branch '2.6' into 2.7
* 2.6: [2.6] Static Code Analysis for Components [Security/Http] Fix test relying on a private property
2 parents 4b136f9 + 08f696c commit 38b9a88

File tree

3 files changed

+5
-7
lines changed

3 files changed

+5
-7
lines changed

src/Symfony/Component/HttpKernel/Client.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ protected function getScript($request)
101101

102102
$r = new \ReflectionClass('\\Symfony\\Component\\ClassLoader\\ClassLoader');
103103
$requirePath = str_replace("'", "\\'", $r->getFileName());
104-
$symfonyPath = str_replace("'", "\\'", realpath(__DIR__.'/../../..'));
104+
$symfonyPath = str_replace("'", "\\'", dirname(dirname(dirname(__DIR__))));
105105
$errorReporting = error_reporting();
106106

107107
$code = <<<EOF

src/Symfony/Component/Intl/Resources/bin/update-data.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,8 +178,7 @@
178178
$compiler = new GenrbCompiler($genrb, $genrbEnv);
179179
$config = new GeneratorConfig($sourceDir.'/data', $icuVersionInDownload);
180180

181-
// Don't wrap "/data" in realpath(), in case the directory does not exist
182-
$baseDir = realpath(__DIR__.'/..').'/data';
181+
$baseDir = dirname(__DIR__).'/data';
183182

184183
//$txtDir = $baseDir.'/txt';
185184
$jsonDir = $baseDir;

src/Symfony/Component/Security/Http/Tests/Firewall/AnonymousAuthenticationListenerTest.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,9 @@ public function testHandleWithTokenStorageHavingNoToken()
5454
$authenticationManager
5555
->expects($this->once())
5656
->method('authenticate')
57-
->with(self::logicalAnd(
58-
$this->isInstanceOf('Symfony\Component\Security\Core\Authentication\Token\AnonymousToken'),
59-
$this->attributeEqualTo('key', 'TheKey')
60-
))
57+
->with($this->callback(function ($token) {
58+
return 'TheKey' === $token->getKey();
59+
}))
6160
->will($this->returnValue($anonymousToken))
6261
;
6362

0 commit comments

Comments
 (0)
0