This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
symfony/tests/Symfony/Tests/Component
Fabien Potencier d6f01df790 merged branch excelwebzone/dev (PR #2706)
Commits
-------

8710a13  Added example to the change log file
c9a2b49  Fixed xml encoder test script, and group `item` tags into an array
a0561e5  Replaced `item` with `*item` when parsing XML string

Discussion
----------

Replaced `item` with `*item` when parsing XML string

---------------------------------------------------------------------------

by fabpot at 2011/11/23 22:14:12 -0800

Tests do not pass:

1) Symfony\Tests\Component\Serializer\Encoder\XmlEncoderTest::testDecode
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
         'key2' => 'val'
-        'A B' => 'bar'
         'Barry' => Array (...)
+        'item' => Array (...)
     )
     'qux' => '1'
 )

.../tests/Symfony/Tests/Component/Serializer/Encoder/XmlEncoderTest.php:173

---------------------------------------------------------------------------

by fabpot at 2011/11/24 22:57:37 -0800

I don't understand the patch anymore. I don't see any use of `*item` in the code.

---------------------------------------------------------------------------

by excelwebzone at 2011/11/24 23:04:07 -0800

I run some testing and you can't use '*item' XML parser reject it. So I modified it to convert it to an array.. Look at the test script change

---------------------------------------------------------------------------

by fabpot at 2011/11/24 23:13:30 -0800

So, you probably need to change the CHANGELOG as well? You should add an example which shows a before/after example.

---------------------------------------------------------------------------

by excelwebzone at 2011/11/24 23:15:51 -0800

Yes, forgot to change that..

---------------------------------------------------------------------------

by fabpot at 2011/11/25 01:27:42 -0800

ping @Seldaek, @lsmith77

---------------------------------------------------------------------------

by Seldaek at 2011/11/25 04:16:43 -0800

There are other meta-names available in the XmlEncoder, @-something for attributes, then there is something happening with a # but I'm not quite sure what. I'm just saying, maybe *item isn't the best name, if it introduces a third metacharacter. Apart from that I'm fine with it.

---------------------------------------------------------------------------

by excelwebzone at 2011/11/25 08:45:31 -0800

Maybe we can rename it to `wildcard` instead

---------------------------------------------------------------------------

by excelwebzone at 2011/11/25 15:12:09 -0800

Any chance we can push this throw?

---------------------------------------------------------------------------

by lsmith77 at 2011/11/27 04:06:25 -0800

here is the old PR #2682
@Seldaek: i think your comment was made for an older version of the patch.

overall I am fine with the change, the Serializer component takes a fairly simple approach. it is also not designed to really produce XML or JSON cleanly from the same data. it will really only be able to output a clean API for one or the other with the same data structure.

---------------------------------------------------------------------------

by excelwebzone at 2011/12/01 06:25:24 -0800

@fabpot can we merge this change
2011-12-01 15:44:03 +01:00
..
BrowserKit merged 2.0 2011-10-15 00:56:57 +02:00
ClassLoader merged 2.0 2011-09-28 16:08:31 +02:00
Config removed unused use statements 2011-11-24 07:16:14 +01:00
Console merged 2.0 2011-11-24 07:16:52 +01:00
CssSelector UnitTest 2011-06-29 18:22:32 +02:00
DependencyInjection merged 2.0 2011-10-29 12:01:39 +02:00
DomCrawler Merge branch '2.0' 2011-11-11 22:52:07 +01:00
EventDispatcher [EventDispatcher] Add name property to Events refs #2572 2011-11-22 09:49:57 +01:00
Finder [Finder] added a convenience method Finder::create() 2011-06-14 14:18:24 +02:00
Form Added ChoiceType test for flattening grouped Choices when expanded 2011-11-26 17:37:07 -08:00
HttpFoundation merged 2.0 2011-11-23 11:23:27 +01:00
HttpKernel [HttpKernel] Fixed failing Stopwatch tests due to usleep() accuracy on Windows 2011-11-27 13:18:15 +01:00
Locale Set error code when number cannot be parsed. Fixes #2389 2011-10-30 22:02:16 +00:00
Process merged 2.0 2011-11-07 20:53:25 +01:00
Routing removed unused use statements 2011-11-24 07:16:14 +01:00
Security merged 2.0 2011-11-24 07:16:52 +01:00
Serializer Fixed xml encoder test script, and group item tags into an array 2011-11-24 09:09:38 -08:00
Templating removed unused use statements 2011-10-29 11:56:30 +02:00
Translation Merge branch '2.0' 2011-11-11 22:52:07 +01:00
Validator [Validators][Type] Added support for ctype_* functions + tests 2011-11-01 13:01:54 +01:00
Yaml Merge branch '2.0' 2011-11-11 22:52:07 +01:00