Skip to content

Commit 7ed7355

Browse files
committed
Merge branch '2.5'
* 2.5: added missing use statements added missing use statement added missing use statement fixed CS [Process] fixed some volatile tests [HttpKernel] fixed a volatile test [HttpFoundation] fixed some volatile tests [Tests] PHPUnit Optimizations Use getPathname() instead of string casting to get BinaryFileReponse file path Conflicts: src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/ConfigurationTest.php src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/php/full.php src/Symfony/Component/Debug/Tests/Exception/FlattenExceptionTest.php src/Symfony/Component/HttpFoundation/Tests/BinaryFileResponseTest.php src/Symfony/Component/Process/Process.php src/Symfony/Component/Stopwatch/Stopwatch.php src/Symfony/Component/Validator/Constraints/AbstractComparisonValidator.php src/Symfony/Component/Validator/Tests/Constraints/GreaterThanOrEqualValidatorTest.php src/Symfony/Component/Yaml/Parser.php src/Symfony/Component/Yaml/Tests/InlineTest.php
2 parents 252b499 + 68224c7 commit 7ed7355

File tree

12 files changed

+39
-39
lines changed

12 files changed

+39
-39
lines changed

DependencyInjection/MainConfiguration.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -341,11 +341,11 @@ private function addProvidersSection(ArrayNodeDefinition $rootNode)
341341
'memory' => array(
342342
'users' => array(
343343
'foo' => array('password' => 'foo', 'roles' => 'ROLE_USER'),
344-
'bar' => array('password' => 'bar', 'roles' => '[ROLE_USER, ROLE_ADMIN]')
344+
'bar' => array('password' => 'bar', 'roles' => '[ROLE_USER, ROLE_ADMIN]'),
345345
),
346-
)
346+
),
347347
),
348-
'my_entity_provider' => array('entity' => array('class' => 'SecurityBundle:User', 'property' => 'username'))
348+
'my_entity_provider' => array('entity' => array('class' => 'SecurityBundle:User', 'property' => 'username')),
349349
))
350350
->disallowNewKeysInSubsequentConfigs()
351351
->isRequired()
@@ -402,8 +402,8 @@ private function addEncodersSection(ArrayNodeDefinition $rootNode)
402402
'Acme\DemoBundle\Entity\User2' => array(
403403
'algorithm' => 'sha512',
404404
'encode_as_base64' => 'true',
405-
'iterations'=> 5000
406-
)
405+
'iterations' => 5000,
406+
),
407407
))
408408
->requiresAtLeastOneElement()
409409
->useAttributeAsKey('class')

DependencyInjection/Security/Factory/RememberMeFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ public function create(ContainerBuilder $container, $id, $config, $userProvider,
6161

6262
if (isset($config['token_provider'])) {
6363
$rememberMeServices->addMethodCall('setTokenProvider', array(
64-
new Reference($config['token_provider'])
64+
new Reference($config['token_provider']),
6565
));
6666
}
6767

DependencyInjection/SecurityExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ private function configureDbalAclProvider(array $config, ContainerBuilder $conta
144144
->addTag('doctrine.event_listener', array(
145145
'connection' => $config['connection'],
146146
'event' => 'postGenerateSchema',
147-
'lazy' => true
147+
'lazy' => true,
148148
))
149149
;
150150

Tests/DependencyInjection/Fixtures/php/container1.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
'switch_user' => true,
7171
'x509' => true,
7272
'logout' => true,
73-
'remember_me' => array('key' => 'TheKey')
73+
'remember_me' => array('key' => 'TheKey'),
7474
),
7575
'host' => array(
7676
'pattern' => '/test',

Tests/DependencyInjection/Fixtures/php/custom_acl_provider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@
55
$container->loadFromExtension('security', array(
66
'acl' => array(
77
'provider' => 'foo',
8-
)
8+
),
99
));

Tests/DependencyInjection/Fixtures/php/merge.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@
1616

1717
'role_hierarchy' => array(
1818
'FOO' => array('MOO'),
19-
)
19+
),
2020
));

Tests/DependencyInjection/Fixtures/php/merge_import.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
'main' => array(
66
'form_login' => array(
77
'login_path' => '/login',
8-
)
9-
)
8+
),
9+
),
1010
),
1111
'role_hierarchy' => array(
1212
'FOO' => 'BAR',

Tests/DependencyInjection/Fixtures/php/remember_me_options.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
'key' => 'TheyKey',
1212
'catch_exceptions' => false,
1313
'token_provider' => 'token_provider_id',
14-
)
15-
)
14+
),
15+
),
1616
),
1717
));

Tests/DependencyInjection/SecurityExtensionTest.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ public function testInvalidCheckPath()
3535
'pattern' => '/secured_area/.*',
3636
'form_login' => array(
3737
'check_path' => '/some_area/login_check',
38-
)
39-
)
40-
)
38+
),
39+
),
40+
),
4141
));
4242

4343
$container->compile();
@@ -59,8 +59,8 @@ public function testFirewallWithoutAuthenticationListener()
5959
'firewalls' => array(
6060
'some_firewall' => array(
6161
'pattern' => '/.*',
62-
)
63-
)
62+
),
63+
),
6464
));
6565

6666
$container->compile();

Tests/Functional/SecurityRoutingIntegrationTest.php

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -96,22 +96,22 @@ public function testSecurityConfigurationForMultipleIPAddresses($config)
9696
*/
9797
public function testSecurityConfigurationForExpression($config)
9898
{
99-
$allowedClient = $this->createClient(array('test_case' => 'StandardFormLogin', 'root_config' => $config), array('HTTP_USER_AGENT' => 'Firefox 1.0'));
100-
$this->assertAllowed($allowedClient, '/protected-via-expression');
101-
102-
$barredClient = $this->createClient(array('test_case' => 'StandardFormLogin', 'root_config' => $config), array());
103-
$this->assertRestricted($barredClient, '/protected-via-expression');
104-
105-
$allowedClient = $this->createClient(array('test_case' => 'StandardFormLogin', 'root_config' => $config), array());
106-
107-
$allowedClient->request('GET', '/protected-via-expression');
108-
$form = $allowedClient->followRedirect()->selectButton('login')->form();
109-
$form['_username'] = 'johannes';
110-
$form['_password'] = 'test';
111-
$allowedClient->submit($form);
112-
$this->assertRedirect($allowedClient->getResponse(), '/protected-via-expression');
113-
$this->assertAllowed($allowedClient, '/protected-via-expression');
114-
}
99+
$allowedClient = $this->createClient(array('test_case' => 'StandardFormLogin', 'root_config' => $config), array('HTTP_USER_AGENT' => 'Firefox 1.0'));
100+
$this->assertAllowed($allowedClient, '/protected-via-expression');
101+
102+
$barredClient = $this->createClient(array('test_case' => 'StandardFormLogin', 'root_config' => $config), array());
103+
$this->assertRestricted($barredClient, '/protected-via-expression');
104+
105+
$allowedClient = $this->createClient(array('test_case' => 'StandardFormLogin', 'root_config' => $config), array());
106+
107+
$allowedClient->request('GET', '/protected-via-expression');
108+
$form = $allowedClient->followRedirect()->selectButton('login')->form();
109+
$form['_username'] = 'johannes';
110+
$form['_password'] = 'test';
111+
$allowedClient->submit($form);
112+
$this->assertRedirect($allowedClient->getResponse(), '/protected-via-expression');
113+
$this->assertAllowed($allowedClient, '/protected-via-expression');
114+
}
115115

116116
private function assertAllowed($client, $path)
117117
{

Tests/Functional/SetAclCommandTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public function testSetAclUser()
4646
$setAclCommandTester->execute(array(
4747
'command' => 'acl:set',
4848
'arguments' => array($grantedPermission1, $grantedPermission2, sprintf('%s:%s', self::OBJECT_CLASS, $objectId)),
49-
'--user' => array(sprintf('%s:%s', self::SECURITY_CLASS, $securityUsername1), sprintf('%s:%s', self::SECURITY_CLASS, $securityUsername2))
49+
'--user' => array(sprintf('%s:%s', self::SECURITY_CLASS, $securityUsername1), sprintf('%s:%s', self::SECURITY_CLASS, $securityUsername2)),
5050
));
5151

5252
$objectIdentity = new ObjectIdentity($objectId, self::OBJECT_CLASS);
@@ -90,7 +90,7 @@ public function testSetAclRole()
9090
$setAclCommandTester->execute(array(
9191
'command' => 'acl:set',
9292
'arguments' => array($grantedPermission, sprintf('%s:%s', strtr(self::OBJECT_CLASS, '\\', '/'), $objectId)),
93-
'--role' => array($role)
93+
'--role' => array($role),
9494
));
9595

9696
$objectIdentity = new ObjectIdentity($objectId, self::OBJECT_CLASS);
@@ -133,7 +133,7 @@ public function testSetAclClassScope()
133133
'command' => 'acl:set',
134134
'arguments' => array($grantedPermission, sprintf('%s:%s', self::OBJECT_CLASS, $objectId)),
135135
'--class-scope' => true,
136-
'--role' => array($role)
136+
'--role' => array($role),
137137
));
138138

139139
$objectIdentity1 = new ObjectIdentity($objectId, self::OBJECT_CLASS);

Tests/Functional/app/Acl/bundles.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
55
new Symfony\Bundle\SecurityBundle\SecurityBundle(),
66
new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
7-
new Symfony\Bundle\SecurityBundle\Tests\Functional\Bundle\AclBundle\AclBundle()
7+
new Symfony\Bundle\SecurityBundle\Tests\Functional\Bundle\AclBundle\AclBundle(),
88
);

0 commit comments

Comments
 (0)