Commit Graph

11078 Commits

Author SHA1 Message Date
Fabien Potencier 3c32fd993d replaced self.version by 2.1.* in composer.json files 2012-09-10 12:53:42 +02:00
Fabien Potencier 487b8c1bbb merged branch aderuwe/issue-5477 (PR #5478)
Commits
-------

690e28e Convert parameter name to lowercase when removing an element from ParameterBag

Discussion
----------

[DependencyInjection] Convert parameter name to lowercase when removing an element from ParameterBag

Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: #5477
License of the code: MIT

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

by sstok at 2012-09-10T08:42:30Z

👍

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

by fabpot at 2012-09-10T09:28:16Z

Shouldn't it be done on the 2.0 branch?

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

by stloyd at 2012-09-10T09:29:35Z

@fabpot AFAIK `2.0` don't have `ParameterBag#remove()` method

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

by aderuwe at 2012-09-10T09:29:52Z

The remove method is not present in 2.0.

On Mon, Sep 10, 2012 at 11:28 AM, Fabien Potencier <notifications@github.com
> wrote:

> Shouldn't it be done on the 2.0 branch?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/symfony/symfony/pull/5478#issuecomment-8418300>.
>
>
2012-09-10 11:46:45 +02:00
Alexander Deruwe 690e28e3df Convert parameter name to lowercase when removing an element from ParameterBag 2012-09-10 10:22:46 +02:00
Fabien Potencier e7059b44c7 bumped Symfony version to 2.1.1-DEV 2012-09-06 12:12:03 +02:00
Fabien Potencier 5745b53d05 updated VERSION for 2.1.0 2012-09-06 11:01:56 +02:00
Fabien Potencier 4035e1a755 Merge branch '2.0'
* 2.0:
  bumped Symfony version to 2.0.18-DEV

Conflicts:
	src/Symfony/Component/HttpKernel/Kernel.php
2012-09-06 10:57:51 +02:00
Fabien Potencier 00ec9b5391 Revert "merged branch Tobion/strictrequirements (PR #5181)"
This reverts commit 2da2a44382, reversing
changes made to 58855475c6.
2012-09-05 17:44:14 +02:00
Fabien Potencier aae4ceea56 Revert "merged branch Tobion/requirementscheck (PR #5187)"
This reverts commit 2cf50b7801, reversing
changes made to 569e29d91f.
2012-09-05 17:44:10 +02:00
Fabien Potencier fdf25289f8 Revert "merged branch Tobion/uselessparamdefaults (PR #5400)"
This reverts commit 0f61b2eb90, reversing
changes made to 5e7723fcbb.
2012-09-05 17:44:05 +02:00
Fabien Potencier 1dd153205b merged branch beberlei/RevertDbalAcl (PR #5253)
Commits
-------

1b5ad17 Revert "Removed MySQL-exclusive usage of unsigned integer from table creation"

Discussion
----------

[Security][DBAL] Revert MySQL unsigned removal

Revert "Removed MySQL-exclusive usage of unsigned integer from table creation"

This reverts commit 57694aaa94.

The problem is underlying in Doctrine DBAL change tracking and should
either be fixed or ignored there.

I opened a ticket on Doctrine Jira http://doctrine-project.org/jira/browse/DBAL-322

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

by fabpot at 2012-08-14T06:40:47Z

I will merge this PR after we have a release of DBAL that includes the fix for DBAL-322.

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

by acasademont at 2012-08-20T08:01:48Z

This was already fixed 2 weeks ago in doctrine/dbal#183 so i guess this can be closed

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

by acasademont at 2012-08-20T08:02:06Z

merged i mean
2012-09-04 16:49:55 +02:00
Fabien Potencier 0919361e2e merged branch eventhorizonpl/100ptc_component_httpfundation (PR #5409)
Commits
-------

3036b00 JsonResponseTest

Discussion
----------

JsonResponseTest

Hi,

This patch adds some tests for JsonResponse.

Best regards,
Michal

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

by eventhorizonpl at 2012-09-01T07:09:12Z

Done. Thanks for the review!
2012-09-04 14:24:42 +02:00
Fabien Potencier 2cd61ab8d9 merged branch eventhorizonpl/100_ptc_symfony_component_class_loader_p3 (PR #5412)
Commits
-------

8a3c8c9 load test

Discussion
----------

load test

Hi,

This patch add test that covers this situation

public static function load($classes, $cacheDir, $name, $autoReload, $adaptive = false, $extension = '.php')
{
  // each $name can only be loaded once per PHP process
  if (isset(self::$loaded[$name])) {
     return;
}

Best regards,
Michal
2012-09-04 14:23:54 +02:00
Fabien Potencier 5040599272 merged branch eventhorizonpl/100ptc_component_httpfundation_p2 (PR #5413)
Commits
-------

0af8778 Response tests

Discussion
----------

Response tests

Hi,

This patch adds some tests to ResponseTest.

Best regards,
Michal

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

by eventhorizonpl at 2012-09-01T09:45:16Z

Fixed, thanks for the review.

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

by eventhorizonpl at 2012-09-02T19:39:26Z

CS fixed. Thanks for the review :)
2012-09-04 14:19:30 +02:00
Fabien Potencier a44c8d8c84 merged branch eventhorizonpl/100ptc_component_httpfundation_p3 (PR #5414)
Commits
-------

c74d9a9 ResponseHeaderBag tests

Discussion
----------

ResponseHeaderBag tests

Hi,

This patch adds some ResponseHeaderBag tests. Now ResponseHeaderBag got 100% test coverage :)

Best regards,
Michal
2012-09-04 14:18:55 +02:00
Fabien Potencier ee51ca8c16 merged branch eventhorizonpl/100ptc_component_httpfundation_p4 (PR #5415)
Commits
-------

b89d4ee StreamedResponseTest

Discussion
----------

StreamedResponseTest

Hi,

This patch adds one test to StreamedResponseTest and fixes another. StreamedResponse has 100% test coverage.

Best regards,
Michal
2012-09-04 14:18:30 +02:00
Fabien Potencier 36c64e0e33 merged branch eventhorizonpl/100ptc_component_httpfundation_p5 (PR #5416)
Commits
-------

21a5841 RedirectResponse tests

Discussion
----------

RedirectResponse tests

Hi,

This patch adds 100% test coverage for RedirectResponse class.

Best regards,
Michal
2012-09-04 14:18:13 +02:00
Fabien Potencier 7888598547 merged branch armetiz/patch-2 (PR #5429)
Commits
-------

6d49bfb Remove "you" word.

Discussion
----------

Remove "you" word.
2012-09-04 12:57:37 +02:00
Thomas Tourlourat 6d49bfb394 Remove "you" word. 2012-09-04 12:35:57 +03:00
Michal Piotrowski 0af87785a7 Response tests
fix things pointed out by Koc

fix things pointed out by stof
2012-09-02 15:37:09 -04:00
Michal Piotrowski 21a5841c6a RedirectResponse tests 2012-09-01 08:25:20 -04:00
Michal Piotrowski b89d4eeb23 StreamedResponseTest 2012-09-01 07:57:21 -04:00
Michal Piotrowski c74d9a90f5 ResponseHeaderBag tests 2012-09-01 07:18:47 -04:00
Michal Piotrowski 8a3c8c9c03 load test 2012-09-01 03:02:36 -04:00
Michal Piotrowski 3036b009a3 JsonResponseTest 2012-09-01 02:56:27 -04:00
Sebastian Bergmann 41ffd006e5 Point to information on how to run the test suite. (closes #5405) 2012-09-01 08:52:18 +02:00
Fabien Potencier 797ba6846a merged branch bschussek/issue4670 (PR #5406)
Commits
-------

04fd5f1 [Form] Fixed PropertyPath to not modify Collection instances (not even their clones)

Discussion
----------

[Form] Fixed PropertyPath to not modify Collection instances

Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: #4670
Todo: -

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

by pocallaghan at 2012-08-31T14:20:52Z

As far as I can see the pull request does fix the issue, which makes sense based on the code change (I didn't know iterator_to_array existed, good call). One thing I would say, I'm not sure on the use in the change to the test case. It's not clear to me what additional protection this extra assertion gives, as both the old and new code seem to pass.

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

by bschussek at 2012-08-31T14:21:46Z

The new assertion is there because not even the old code (`clone`) was tested.

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

by stof at 2012-08-31T14:37:38Z

@bschussek but was it failing without the code change ?

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

by bschussek at 2012-08-31T22:12:00Z

@stof It was not, but I was unable to write a good test for the change within reasonable time. I added an explanatory comment instead.
2012-09-01 08:47:43 +02:00
Fabien Potencier 07ec1cb63b [Security] fixed typo in a test 2012-08-31 19:17:17 +02:00
Bernhard Schussek 04fd5f1b21 [Form] Fixed PropertyPath to not modify Collection instances (not even their clones) 2012-08-31 14:34:27 +02:00
Fabien Potencier c0673d77d0 merged branch stof/fix_testsuite (PR #5403)
Commits
-------

7ef6295 Removed the unnecessary file include

Discussion
----------

Removed the unnecessary file include

As of Doctrine 2.2, the ORM annotations can be found by the autoloader directly.

This will also avoid breaking the testsuite in case the dev deps have not been installed as the ORM would not be available in this case (the tests relying on the ORM should already be skipped when it is not available). See #5402
2012-08-31 13:41:36 +02:00
Christophe Coevoet 7ef629525e Removed the unnecessary file include
As of Doctrine 2.2, the ORM annotations can be found by the autoloader
directly.
2012-08-31 13:16:54 +02:00
Fabien Potencier 0f61b2eb90 merged branch Tobion/uselessparamdefaults (PR #5400)
Commits
-------

cb7e3f5 [Routing] added route compile check to identify a default value of a required variable that does not match the requirement

Discussion
----------

[Routing] added route compile check to identify a bad default value

BC break: yes but only for strange route definitions

See the exception message in code for the reasoning.

An exception is thrown for a __required__ variable that __has a default__ that __doesn't match__ the requirement.
So optional variables can of course still have a default that don't meet the requirement, which is useful.
This helps to identify useless route definitions at compile time instead of when generating or matching a URL.
2012-08-31 11:55:46 +02:00
Fabien Potencier 5e7723fcbb merged branch janmarek/patch-1 (PR #5202)
Commits
-------

890aea2 FileLocatorInterface used in typehint instead of FileLocator

Discussion
----------

FileLocatorInterface used in typehint instead of FileLocator

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

by stof at 2012-08-30T22:09:39Z

@fabpot this makes sense (and it is BC)

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

by mvrhov at 2012-08-31T08:34:17Z

What's wrong with Interface hint? I always hint interface when available as this means that I can inject whatever class implementing that interface.
2012-08-31 11:52:07 +02:00
Tobias Schultze cb7e3f5edb [Routing] added route compile check to identify a default value of a required variable that does not match the requirement 2012-08-31 08:36:21 +02:00
Fabien Potencier 2cf50b7801 merged branch Tobion/requirementscheck (PR #5187)
Commits
-------

3363832 extended phpdoc of ConfigurableRequirementsInterface
5f64503 [Routing] added test for disabled requirements check
4225869 [Routing] allow disabling the requirements check on URL generation

Discussion
----------

[Routing] allow disabling the requirements check on URL generation

This adds the possibility to disable the requirements check (`strict_requirements = null`) on URL generation.

To sum up, here the possibilities:
- `strict_requirements = true`: throw exception for mismatching requirements (most useful in development environment).
- `strict_requirements = false`: don't throw exception but return null as URL for mismatching requirements and log it (useful when you cannot control all params because they come from third party libs or something but don't want to have a 404 in production environment. it logs the mismatch so you can review it).
- `strict_requirements = null`: Return the URL with the given parameters without checking the requirements at all. When generating an URL you should either trust your params or you validated them beforehand because otherwise it would break your link anyway (just as with strict_requirements=false). So in production environment you should know that params allways pass the requirements. Thus you could disable the check on each URL generation for performance reasons. If you have 300 links on a page and each URL at least one param you safe 300 unneeded `preg_match` calls. I tested the performance in one of my projects. The rendering time of a single template that contains ~300 links with several params was reduced from avg. 46ms to avg. 42ms. That are 8.7% reduction in the twig layer where the links are created on each request. So this option combines the improved usability of strict_requirements=false with an additional increased performance.

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

by fabpot at 2012-08-30T13:40:38Z

Can you put the comment about all the possibilities you have mentioned here in the phpdoc for future reference? Thanks.

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

by Tobion at 2012-08-30T13:49:25Z

In `ConfigurableRequirementsInterface` or which phpdoc would you like to have it? Because `ConfigurableRequirementsInterface` already has it explained. But I can extend its description if thats what you mean.

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

by fabpot at 2012-08-30T13:50:40Z

The comment in the PR is more explicit and more detailed than the one in the interface. So, yes, basically, it would be great if you can move all the information in the interface phpdoc.

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

by Tobion at 2012-08-30T14:35:59Z

Done.
2012-08-30 16:40:08 +02:00
Tobias Schultze 33638320f2 extended phpdoc of ConfigurableRequirementsInterface 2012-08-30 16:35:30 +02:00
Tobias Schultze 5f64503132 [Routing] added test for disabled requirements check 2012-08-30 15:08:30 +02:00
Tobias Schultze 4225869939 [Routing] allow disabling the requirements check on URL generation 2012-08-30 15:08:29 +02:00
Fabien Potencier 569e29d91f merged branch romainneutron/ProcessExitCode (PR #5386)
Commits
-------

407db65 Add @Seldaek remote modifications
3bfb976 Add unit test demonstrating bad exit code getter for a failing process

Discussion
----------

Add unit test demonstrating bad exit code getter for a failing process

Since symfony/symfony@7b63428698 exit code are not well handled anymore.

The unit test provided with this PR demonstrates it

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

by fabpot at 2012-08-30T11:05:05Z

ping @Seldaek

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

by stof at 2012-08-30T11:13:13Z

We probably need to enable the workaround only when sigchild is used.

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

by Seldaek at 2012-08-30T12:51:22Z

Ok I figured out the problem, the hack is even hackier I guess now, but it should work for people with and without --enable-sigchild at least.
2012-08-30 15:04:53 +02:00
Romain Neutron 407db6510b Add @Seldaek remote modifications 2012-08-30 14:49:05 +02:00
Romain Neutron 3bfb9762d7 Add unit test demonstrating bad exit code getter for a failing process 2012-08-30 12:55:38 +02:00
Fabien Potencier 2982e6e678 merged branch rdohms/html5-regexp (PR #5382)
Commits
-------

7503ec9 Issue #5307: HTML regexp when match is false

Discussion
----------

Issue #5307: HTML regexp when match is false

When match is false the html5 validation regexp should be either inverted or not added.
Since we are in RC added a fix where this is not added, but marked a @todo so that this
can be revisited and we try to inverse the regexp instead.

Discussed in #5307.

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

by bschussek at 2012-08-30T08:40:06Z

👍 once the CS issue is fixed.

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

by rdohms at 2012-08-30T09:23:57Z

Could swear that was the CS in PSR-1 or 2, anyway, fixed.

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

by fabpot at 2012-08-30T09:26:07Z

Can you squash your commits before I merge? Thanks.

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

by rdohms at 2012-08-30T09:54:26Z

@fabpot done.
2012-08-30 12:00:56 +02:00
Rafael Dohms 7503ec954f Issue #5307: HTML regexp when match is false
When match is false the html5 validation regexp should be either inverted or not added.
Since we are in RC added a fix where this is not added, but marked a @todo so that this
can be revisited and we try to inverse the regexp instead.
2012-08-30 11:53:07 +02:00
Fabien Potencier 03f34a9765 merged branch mpiecko/master (PR #5280)
Commits
-------

58ebd1b [Form] Fixed error bubbling from DateTime widget - Issue #5270
8ea1607 Update src/Symfony/Component/Form/Extension/Core/Type/DateTimeType.php

Discussion
----------

[Form] Fixed error bubbling from DateTime widget - Issue #5270

This is related to https://github.com/symfony/symfony/issues/5270

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

by mpiecko at 2012-08-16T19:37:45Z

Travisbot shows something like this in it's log:

    [Composer\Downloader\TransportException] The "http://nodeload.github.com/phingofficial/phing/zipball/2.4.12" file could not be downloaded (HTTP/1.1 500 Internal Server Error)

So is it my PR ot Travis CI who fails ... ? I saw this error in some other PR's ...

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

by stloyd at 2012-08-16T20:40:39Z

It's GitHub =)

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

by mpiecko at 2012-08-17T09:36:31Z

Bad GitHub :)

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

by bschussek at 2012-08-17T11:21:39Z

Could you please add a test to DateTimeTypeTest?

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

by mpiecko at 2012-08-17T12:23:40Z

Sure!

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

by bschussek at 2012-08-30T08:20:08Z

👍
2012-08-30 10:23:27 +02:00
Fabien Potencier 548db6dfcd fixed typo 2012-08-30 09:43:00 +02:00
Fabien Potencier 2da2a44382 merged branch Tobion/strictrequirements (PR #5181)
Commits
-------

0706d18 [Routing] fixed 4 bugs in the UrlGenerator

Discussion
----------

[Routing] UrlGenerator: fixed missing query param and some ignored requirements

This was pretty hard to figure out. I could fix 4 bugs and refactor the code to safe 2 variables and several assignments. Sorry for doing this in one commit, but they were highly interdependent.
See the added tests for what was fixed. The most obvious bug was that a query param was ignored if it had by accident the same name as a default param (but wasn't used in the path).
In 3 cases it generated the wrong URL that wouldn't match this route. The generator wrongly ignored either the requirements or the passed parameter. I had to adjust one test that was asserting something wrong (see comments).

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

by Tobion at 2012-08-13T14:22:35Z

ping @fabpot

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

by Tobion at 2012-08-29T17:53:07Z

@fabpot I think it's important to merge this before 2.1 final.
2012-08-30 09:34:36 +02:00
Fabien Potencier 58855475c6 [HttpFoundation] added missing property declarations (refs #5379) 2012-08-30 09:11:02 +02:00
Fabien Potencier 24ae90deee merged branch Baachi/test-refactoring (PR #5379)
Commits
-------

f2d8a8a Refactor the unit test for the "MongoDbSessionHandler"

Discussion
----------

[HttpFoundation] Refactor the unit test for the "MongoDbSessionHandler"

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: -
Todo: -
License of the code: MIT
Documentation PR: -

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

by drak at 2012-08-29T19:49:49Z

Big +1 from me. Exactly how these kind of tests should be written.
2012-08-30 09:10:05 +02:00
Fabien Potencier c4fa0b1a3c merged branch sli-systems/master (PR #5380)
Commits
-------

cf4189b Move remember me ResponseListener from security bundle into security component

Discussion
----------

Move remember me response listener from security bundle into security component

...ponent

This move allows to implement the remember me feature in Silex without having to reference the security bundle.

This is the pull request for issue #5264
2012-08-30 07:48:38 +02:00
DerManoMann cf4189bdaf Move remember me ResponseListener from security bundle into security component
This move allows to implement the remember me feature in Silex without having to reference the security bundle.
2012-08-30 11:15:49 +12:00
Markus Bachmann f2d8a8a85b Refactor the unit test for the "MongoDbSessionHandler" 2012-08-29 21:23:32 +02:00