Commit Graph

16897 Commits

Author SHA1 Message Date
Fabien Potencier
f15ea50b17 minor #10376 [Component][Serializer] Add fluent interface to GetSetMethodNormalizer (alexsegura)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[Component][Serializer] Add fluent interface to GetSetMethodNormalizer

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | N/A
| License       | MIT
| Doc PR        | N/A

Commits
-------

2d42533 [Component][Serializer] Add fluent interface to GetSetMethodNormalizer
2014-03-04 21:00:43 +01:00
Fabien Potencier
50579442f8 minor #10380 fixed some HHVM bugs (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

fixed some HHVM bugs

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

This is a workaround for facebook/hhvm#1161. I made the change as the workaround does the same thing and the eval is part of unit tests.

Commits
-------

d014dac made Cookie stringification more robust
fa24749 [Yaml] fix for a HHVM bug
2014-03-04 20:15:40 +01:00
Fabien Potencier
535d6c8096 minor #10377 [HttpKernel] Fix gitignore (florianv)
This PR was submitted for the 2.4-dev branch but it was merged into the 2.4 branch instead (closes #10377).

Discussion
----------

[HttpKernel] Fix gitignore

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

The kernel rootDir is Fixtures:

https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Tests/KernelTest.php#L787-L789

https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Tests/KernelTest.php#L800-L802

Commits
-------

9980ba2 [HttpKernel] Fix gitignore
2014-03-04 18:06:29 +01:00
florianv
0551363a84 Fix gitignore 2014-03-04 18:06:29 +01:00
Fabien Potencier
d014dacce3 made Cookie stringification more robust 2014-03-04 17:47:46 +01:00
Fabien Potencier
fa24749537 [Yaml] fix for a HHVM bug 2014-03-04 17:04:39 +01:00
Alexandre Segura
2d42533964 [Component][Serializer] Add fluent interface to GetSetMethodNormalizer 2014-03-04 15:58:09 +01:00
Fabien Potencier
bc38d76f94 minor #10366 [FrameworkBundle] set a default value for gc_probability (fabpot)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[FrameworkBundle] set a default value for gc_probability

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | refs #10349
| License       | MIT
| Doc PR        | n/a

This sets the `gc_probability` to 1 by default (which is the default value in PHP). That should help mitigate #10349.

Commits
-------

7e1bdd7 [FrameworkBundle] set a default value for gc_probability
2014-03-04 10:28:13 +01:00
Fabien Potencier
1948d3647f Merge branch '2.4'
* 2.4:
  Revert "[HttpFoundation] removed test file not related to 2.3"
  [HttpFoundation] removed test file not related to 2.3
  [HttpKernel] fixed CS
  Add tests for RequestStack class
2014-03-04 08:36:44 +01:00
Fabien Potencier
91ceddcb42 Revert "[HttpFoundation] removed test file not related to 2.3"
This reverts commit 60ed3880d7.
2014-03-04 08:36:26 +01:00
Fabien Potencier
29edeeae66 Merge branch '2.3' into 2.4
* 2.3:
  [HttpFoundation] removed test file not related to 2.3
  [HttpKernel] fixed CS
  Add tests for RequestStack class
2014-03-04 08:36:00 +01:00
Fabien Potencier
f6bc83fc07 minor #10373 added the BC docs to the contributing file (fabpot)
This PR was merged into the 2.5-dev branch.

Discussion
----------

added the BC docs to the contributing file

Commits
-------

2f9432a added the BC docs to the contributing file
2014-03-04 08:34:34 +01:00
Fabien Potencier
b3cf27a184 minor #10372 [HttpKernel] fixed CS (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpKernel] fixed CS

Commits
-------

7539e41 [HttpKernel] fixed CS
2014-03-04 08:33:50 +01:00
Fabien Potencier
60ed3880d7 [HttpFoundation] removed test file not related to 2.3 2014-03-04 08:33:02 +01:00
Fabien Potencier
2f9432a45b added the BC docs to the contributing file 2014-03-04 08:26:38 +01:00
Fabien Potencier
7539e4197e [HttpKernel] fixed CS 2014-03-04 08:21:33 +01:00
Fabien Potencier
69d2c8e715 Merge branch '2.4'
* 2.4:
  [HttpKernel] fixed unit tests when using phpunit.phar
  add expression request matcher tests
2014-03-03 23:00:45 +01:00
Fabien Potencier
1c02456179 minor #10369 [HttpKernel] fixed unit tests when using phpunit.phar (fabpot)
This PR was merged into the 2.4 branch.

Discussion
----------

[HttpKernel] fixed unit tests when using phpunit.phar

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

0edb192 [HttpKernel] fixed unit tests when using phpunit.phar
2014-03-03 23:00:13 +01:00
Fabien Potencier
0edb192d55 [HttpKernel] fixed unit tests when using phpunit.phar 2014-03-03 22:46:04 +01:00
Fabien Potencier
e778cf19cd fixed previous merge 2014-03-03 19:01:36 +01:00
Fabien Potencier
0aeb3945bc feature #9739 [FrameworkBundle] Extract KernelTestCase from WebTestCase (johnkary)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[FrameworkBundle] Extract KernelTestCase from WebTestCase

| Q             | A
| ------------- | ---
| Bug fix?      | No
| New feature?  | Yes
| BC breaks?    | No
| Deprecations? | No
| Tests pass?   | Yes
| Fixed tickets | None
| License       | MIT
| Doc PR        | symfony/symfony-docs#3311

Previous discussion is in #7704. Opened new PR to target master branch.

This idea came to me while reading the Cookbook article [How to create a Console Command - Testing Commands](http://symfony.com/doc/master/cookbook/console/console_command.html#testing-commands) and I wanted to hear feedback from others before submitting a patch.

Basically the Cookbook article states that when testing a Command that extending `WebTestCase` is a good way to get access to the Kernel and thus the Container. This struck me as weird because I was wanting to test a Command, which doesn't really have anything to do with "the web."

Currently `WebTestCase` doesn't do anything internally that looks like web-specific work, and the class docblock itself states "WebTestCase is the base class for functional tests.".

After a suggestion in #7704 by @beberlei, I decided to take his advice and now have the following implementation:

Extracted a new class `KernelTestCase` from `WebTestCase` and instead allow WebTestCase to extend KernelTestCase. Pulled all methods up into KernelTestCase except `createClient()` because `createClient()` is focused solely on creating a Client for issuing web-based requests.

Benjamin's solution provides us a clear extension point from `KernelTestCase` for Command-based tests and also provides 100% backwards-compatibility without the need to deprecate WebTestCase.

Commits
-------

c4f14fb Extract new base test class KernelTestClass
2014-03-03 19:00:51 +01:00
Fabien Potencier
4d31d2f3cc fixed CS 2014-03-03 18:47:50 +01:00
Fabien Potencier
c4b8e03332 feature #9852 [Translation] Added template for relative file paths in FileDumper (florianv)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[Translation] Added template for relative file paths in FileDumper

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/9845
| License       | MIT
| Doc PR        |

Added ability to support templates for relative paths to translation files.
The file dumpers will try to create the directories if not existing.
Also made `IcuResFileDumper` extending `FileDumper`.

Commits
-------

a04175e Changed placeholders
623d149 Added a ConcreteDumper
84f0902 [Translation] Added template for relative file paths
2014-03-03 18:46:58 +01:00
Fabien Potencier
3e7da99de5 minor #10322 [HttpFoundation][Tests] Add expression request matcher tests (inalgnu)
This PR was submitted for the 2.4-dev branch but it was merged into the 2.4 branch instead (closes #10322).

Discussion
----------

[HttpFoundation][Tests] Add expression request matcher tests

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

76fe21d [HttpFoundation][Tests] add expression request matcher tests
2014-03-03 18:30:42 +01:00
inalgnu
16b48d657f add expression request matcher tests 2014-03-03 18:30:41 +01:00
Fabien Potencier
a9c174d639 minor #10326 [HttpFoundation][Tests] Add tests for RequestStack class (inalgnu)
This PR was submitted for the 2.3-dev branch but it was merged into the 2.3 branch instead (closes #10326).

Discussion
----------

[HttpFoundation][Tests] Add tests for RequestStack class

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

6f25d39 [HttpFoundation][Tests] Add tests for RequestStack class
2014-03-03 18:28:54 +01:00
Inal DJAFAR
466e5b87b0 Add tests for RequestStack class 2014-03-03 18:28:54 +01:00
Fabien Potencier
786c956a11 feature #10368 [FrameworkBundle] Added a translation:debug command (fabpot)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[FrameworkBundle] Added a translation:debug command

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

This PR is based on #10076 but fixes a bunch of issues for edge cases. It also uses the new Table helper.

Original description:

This pull request adds a `translation:debug` command that can be used to inspect unused / missing messages and compare them with the fallback ones (for example to detect copy pasted strings). This is inspired by this ruby project https://github.com/glebm/i18n-tasks

Example of output:

![image](https://f.cloud.github.com/assets/47313/2311673/84ae301c-a2f3-11e3-8bf6-96034369e46c.png)

Commits
-------

f039bde [FrameworkBundle] fixed edge cases for translation:debug and tweaked the output
597a310 Added a translation:debug command
2014-03-03 18:25:58 +01:00
Fabien Potencier
f039bde3d8 [FrameworkBundle] fixed edge cases for translation:debug and tweaked the output 2014-03-03 18:24:37 +01:00
Fabien Potencier
5ea64372db [FrameworkBundle] refactored the built-in web server 2014-03-03 18:22:18 +01:00
florianv
a04175ec9c Changed placeholders 2014-03-03 18:14:46 +01:00
florianv
623d149cad Added a ConcreteDumper 2014-03-03 18:10:14 +01:00
florianv
84f09024b4 [Translation] Added template for relative file paths 2014-03-03 18:10:14 +01:00
Fabien Potencier
887e6ff64d feature #10017 [FrameworkBundle] Add HHVM support for built-in web server (RickySu)
This PR was squashed before being merged into the 2.5-dev branch (closes #10017).

Discussion
----------

[FrameworkBundle] Add HHVM support for built-in web server

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | no
| License       | MIT

Using HHVM as built-in web server for development from console.

```
hhvm app/console server:run
```

Commits
-------

66798ba9 [FrameworkBundle] Add HHVM support for built-in web server
2014-03-03 17:50:00 +01:00
Ricky Su
66798ba904 [FrameworkBundle] Add HHVM support for built-in web server 2014-03-03 17:49:59 +01:00
florianv
597a3107bc Added a translation:debug command 2014-03-03 17:12:20 +01:00
Fabien Potencier
2a1592383d feature #10100 [ClassLoader] A PSR-4 compatible class loader (derrabus)
This PR was squashed before being merged into the 2.5-dev branch (closes #10100).

Discussion
----------

[ClassLoader] A PSR-4 compatible class loader

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

This is a PSR-4 compatible class loader that I'd like to contribute to the ClassLoader component. Since PSR-4 is the most recent FIG standard for an autoloader, I thought a compatible loader should be part of a feature-complete ClassLoader component.

See: http://www.php-fig.org/psr/psr-4/

PSR-4 does neither replace PSR-0, nor are those standards 100% compatible. This is why I implemented the standard as a new class.

If you decide that my PR is worth merging, I would also provide a PR for symfony-docs with a documentation.

Commits
-------

6837df3 [ClassLoader] A PSR-4 compatible class loader
2014-03-03 17:01:36 +01:00
Alexander M. Turek
6837df3e14 [ClassLoader] A PSR-4 compatible class loader 2014-03-03 17:01:35 +01:00
Fabien Potencier
725f7abc87 bug #10367 [HttpKernel] fixed serialization of the request data collector (fabpot)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[HttpKernel] fixed serialization of the request data collector

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10361
| License       | MIT
| Doc PR        | n/a

This fixes a regression introduced in #10352.

Commits
-------

6102f99 [HttpKernel] fixed serialization of the request data collector
2014-03-03 16:55:29 +01:00
Fabien Potencier
4a1639acc7 feature #10314 [Serializer] added support for is.* methods in GetSetMethodNormalizer (tiraeth)
This PR was squashed before being merged into the 2.5-dev branch (closes #10314).

Discussion
----------

[Serializer] added support for is.* methods in GetSetMethodNormalizer

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10297
| License       | MIT
| Doc PR        | N/A

Using ``is`` prefix for boolean variables is considered a standard, not only in PHP but also in Java (from which Symfony2 derives lot standards).

I was not sure if this is BCB but answered "no". Was not sure if I should update ``CHANGELOG`` file and did so, but if you find it irrelevant, go ahead and merge without it. I don't know if I should create a PR for docs because it does not explicitly say that the normalizer supports only ``get.*`` methods as getters.

_Note: Objects that contain behaviour also can use other prefixes like ``can``, ``has``, ``should``, but their presence in ``GetSetMethodNormalizer`` is relevant as they do not provide state (``has`` is debatable)._

Commits
-------

480219f [Serializer] added support for is.* methods in GetSetMethodNormalizer
2014-03-03 16:53:45 +01:00
Marcin Chwedziak
480219f1d3 [Serializer] added support for is.* methods in GetSetMethodNormalizer 2014-03-03 16:52:29 +01:00
Fabien Potencier
6102f994bc [HttpKernel] fixed serialization of the request data collector 2014-03-03 16:26:22 +01:00
Fabien Potencier
98c3fe7ef3 feature #10365 [Console] deprecated TableHelper in favor of Table (fabpot)
This PR was merged into the 2.5-dev branch.

Discussion
----------

[Console] deprecated TableHelper in favor of Table

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #9788, #9680, #9325
| License       | MIT
| Doc PR        | symfony/symfony-docs#3627

This PR makes the Table helper stateless. It also adds a way to define global styles and to change/tweak existing styles easily.

The second commit adds the possibility to add a separator anywhere in the table output.

Commits
-------

21784ce [Console] make it possible to pass a style directly to Table::setStyle()
14caaec [Console] added the possibility to insert a table separator anywhere in a table output
39c495f [Console] deprecated TableHelper in favor of Table
2014-03-03 14:53:19 +01:00
Fabien Potencier
7e1bdd73c5 [FrameworkBundle] set a default value for gc_probability 2014-03-03 14:18:29 +01:00
Fabien Potencier
21784ced7a [Console] make it possible to pass a style directly to Table::setStyle() 2014-03-03 14:12:10 +01:00
Fabien Potencier
14caaec5f6 [Console] added the possibility to insert a table separator anywhere in a table output 2014-03-03 14:12:09 +01:00
Fabien Potencier
39c495f814 [Console] deprecated TableHelper in favor of Table 2014-03-03 14:12:09 +01:00
Fabien Potencier
77bfac719c Merge branch '2.4'
* 2.4:
  [Form][2.3] Fixes empty file-inputs getting treated as extra field.
  changed some PHPUnit assertions to more specific ones
  fixed Kernel::stripComments() normalizing new-lines
  added a BC comment
  Update FileLoader to fix issue #10339
  bumped Symfony version to 2.3.12
  updated VERSION for 2.3.11
  update CONTRIBUTORS for 2.3.11
  updated CHANGELOG for 2.3.11
  Throw exception when unable to normalize embedded object
  Fixed evaluation of short circuit operators
  Follow-up to #10312: Fixed minor performance related issues in Yaml\Inline.
  [2.4][HttpKernel] Fix issue #10209 When the profiler has `only_exception` option activated and a subrequest throw an exception, the parent profile cannot be found.
2014-03-03 13:53:01 +01:00
Fabien Potencier
09b0a40953 Merge branch '2.3' into 2.4
* 2.3:
  [Form][2.3] Fixes empty file-inputs getting treated as extra field.
2014-03-03 13:52:50 +01:00
Fabien Potencier
485efad0bb bug #10251 [Form][2.3] Fixes empty file-inputs getting treated as extra field. (jenkoian)
This PR was squashed before being merged into the 2.3 branch (closes #10251).

Discussion
----------

[Form][2.3] Fixes empty file-inputs getting treated as extra field.

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #8575 (https://github.com/symfony/symfony/pull/8575#issuecomment-34867485)
| License       | MIT

Re-applies 968fe23 (PR #8575).

The test for this already exists, it was just this line that got overwritten by eb9f76d5ba (diff-ca5e25b47f3ecc94cd557946aeb486c6L542)

To clarify, this is a PR into 2.3 branch - this already exists in 2.4 (and later from this PR: https://github.com/symfony/symfony/pull/9146)

Commits
-------

8d99d75 [Form][2.3] Fixes empty file-inputs getting treated as extra field.
2014-03-03 13:52:14 +01:00