Skip to content

Commit 09d96d5

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 0ce70f5 + a95c047 commit 09d96d5

File tree

7 files changed

+17
-22
lines changed

7 files changed

+17
-22
lines changed

Encoder/JsonDecode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ private function resolveContext(array $context)
132132
$defaultOptions = array(
133133
'json_decode_associative' => $this->associative,
134134
'json_decode_recursion_depth' => $this->recursionDepth,
135-
'json_decode_options' => 0
135+
'json_decode_options' => 0,
136136
);
137137

138138
return array_merge($defaultOptions, $context);

Encoder/JsonEncode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
*/
2121
class JsonEncode implements EncoderInterface
2222
{
23-
private $options ;
23+
private $options;
2424
private $lastError = JSON_ERROR_NONE;
2525

2626
public function __construct($bitmask = 0)

Encoder/XmlEncoder.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,6 @@ public function decode($data, $format, array $context = array())
9999
// todo: throw an exception if the root node name is not correctly configured (bc)
100100

101101
if ($rootNode->hasChildNodes()) {
102-
103102
$xpath = new \DOMXPath($dom);
104103
$data = array();
105104
foreach ($xpath->query('namespace::*', $dom->documentElement) as $nsNode) {

Serializer.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,6 @@ public function supportsDenormalization($data, $type, $format = null)
164164
*/
165165
private function getNormalizer($data, $format)
166166
{
167-
168167
$class = get_class($data);
169168
if (isset($this->normalizerCache[$class][$format])) {
170169
return $this->normalizerCache[$class][$format];

Tests/Encoder/XmlEncoderTest.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,11 @@ public function testAttributes()
6767
$obj->xmlFoo = array(
6868
'foo-bar' => array(
6969
'@id' => 1,
70-
'@name' => 'Bar'
70+
'@name' => 'Bar',
7171
),
7272
'Foo' => array(
7373
'Bar' => "Test",
74-
'@Type' => 'test'
74+
'@Type' => 'test',
7575
),
7676
'föo_bär' => 'a',
7777
"Bar" => array(1,2,3),
@@ -141,7 +141,7 @@ public function testEncodeScalarRootAttributes()
141141
{
142142
$array = array(
143143
'#' => 'Paul',
144-
'@gender' => 'm'
144+
'@gender' => 'm',
145145
);
146146

147147
$expected = '<?xml version="1.0"?>'."\n".
@@ -154,7 +154,7 @@ public function testEncodeRootAttributes()
154154
{
155155
$array = array(
156156
'firstname' => 'Paul',
157-
'@gender' => 'm'
157+
'@gender' => 'm',
158158
);
159159

160160
$expected = '<?xml version="1.0"?>'."\n".
@@ -288,7 +288,7 @@ public function testDecodeScalarRootAttributes()
288288

289289
$expected = array(
290290
'#' => 'Peter',
291-
'@gender' => 'M'
291+
'@gender' => 'M',
292292
);
293293

294294
$this->assertEquals($expected, $this->encoder->decode($source, 'xml'));
@@ -302,7 +302,7 @@ public function testDecodeRootAttributes()
302302
$expected = array(
303303
'firstname' => 'Peter',
304304
'lastname' => 'Mac Calloway',
305-
'@gender' => 'M'
305+
'@gender' => 'M',
306306
);
307307

308308
$this->assertEquals($expected, $this->encoder->decode($source, 'xml'));
@@ -321,8 +321,8 @@ public function testDecodeArray()
321321
$expected = array(
322322
'people' => array('person' => array(
323323
array('firstname' => 'Benjamin', 'lastname' => 'Alexandre'),
324-
array('firstname' => 'Damien', 'lastname' => 'Clay')
325-
))
324+
array('firstname' => 'Damien', 'lastname' => 'Clay'),
325+
)),
326326
);
327327

328328
$this->assertEquals($expected, $this->encoder->decode($source, 'xml'));
@@ -345,7 +345,7 @@ public function testDecodeIgnoreWhiteSpace()
345345
XML;
346346
$expected = array('person' => array(
347347
array('firstname' => 'Benjamin', 'lastname' => 'Alexandre'),
348-
array('firstname' => 'Damien', 'lastname' => 'Clay')
348+
array('firstname' => 'Damien', 'lastname' => 'Clay'),
349349
));
350350

351351
$this->assertEquals($expected, $this->encoder->decode($source, 'xml'));
@@ -357,11 +357,11 @@ public function testDecodeWithoutItemHash()
357357
$obj->xmlFoo = array(
358358
'foo-bar' => array(
359359
'@key' => "value",
360-
'item' => array("@key" => 'key', "key-val" => 'val')
360+
'item' => array("@key" => 'key', "key-val" => 'val'),
361361
),
362362
'Foo' => array(
363363
'Bar' => "Test",
364-
'@Type' => 'test'
364+
'@Type' => 'test',
365365
),
366366
'föo_bär' => 'a',
367367
"Bar" => array(1,2,3),
@@ -370,11 +370,11 @@ public function testDecodeWithoutItemHash()
370370
$expected = array(
371371
'foo-bar' => array(
372372
'@key' => "value",
373-
'key' => array('@key' => 'key', "key-val" => 'val')
373+
'key' => array('@key' => 'key', "key-val" => 'val'),
374374
),
375375
'Foo' => array(
376376
'Bar' => "Test",
377-
'@Type' => 'test'
377+
'@Type' => 'test',
378378
),
379379
'föo_bär' => 'a',
380380
"Bar" => array(1,2,3),
@@ -464,7 +464,7 @@ protected function getNamespacedArray()
464464
),
465465
array(
466466
'title' => 'title2',
467-
)
467+
),
468468
),
469469
'Barry' => array(
470470
'@size' => 'large',

Tests/Fixtures/DenormalizableDummy.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,7 @@
1616

1717
class DenormalizableDummy implements DenormalizableInterface
1818
{
19-
2019
public function denormalize(DenormalizerInterface $denormalizer, $data, $format = null, array $context = array())
2120
{
22-
2321
}
24-
2522
}

Tests/Normalizer/GetSetMethodNormalizerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ public function provideCallbacks()
216216
),
217217
'baz',
218218
array('foo' => '', 'bar' => null, 'baz' => true),
219-
'Null an item'
219+
'Null an item',
220220
),
221221
array(
222222
array(

0 commit comments

Comments
 (0)