Commit Graph

12558 Commits

Author SHA1 Message Date
Drak
df0623f98f Making it easier to grab the PR template. 2012-12-15 21:57:27 +00:00
Florin Patan
254d40bca0 Small fix for WPB when there is no menu item 2012-12-15 23:53:39 +02:00
Florin Patan
5a73d5512f Added small test to check if time limit works 2012-12-15 23:45:42 +02:00
Florin Patan
7f6e99bc4d Fixed MongoDB storage missing time range. Fixed UI not searching properly. Removed unnecessary time query. 2012-12-15 23:37:18 +02:00
Florin Patan
3a0ed584df Added ability to search by time when using the profiler 2012-12-15 22:42:20 +02:00
Fabien Potencier
ab64da5671 [Locale] fixed a test 2012-12-15 18:28:15 +01:00
Bernhard Schussek
e713bb4e7e Fixed failing test 2012-12-15 18:20:34 +01:00
Fabien Potencier
f9297c103e merged branch bschussek/bugfix (PR #6371)
This PR was merged into the master branch.

Commits
-------

2f6507b [Form] Fixed failing test

Discussion
----------

[Form] Fixed failing test

Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: -
Todo: -
License of the code: MIT
Documentation PR: -
2012-12-15 18:13:18 +01:00
Bernhard Schussek
2f6507ba18 [Form] Fixed failing test 2012-12-15 18:04:13 +01:00
Fabien Potencier
1f5b4a1648 [FrameworkBundle] fixed broken tests 2012-12-15 17:50:23 +01:00
Fabien Potencier
0ed2bdde84 Merge branch '2.1'
* 2.1:
  [FrameworkBundle] fixed broken tests
  [FrameworkBundle] Fixed logic under test environment.
  [Session] Added exception to save method
  [Session] Fixed a bug with the TestListener
  Added comment
  [FrameworkBundle] Added tests for trusted_proxies configuration.
  [FrameworkBundle] Added a check on file mime type for CodeHelper::fileExcerpt()
  checked for a potentially missing key
  [FrameworkBundle] used the new method for trusted proxies
  remove realpath call

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php
2012-12-15 17:49:38 +01:00
Fabien Potencier
47a56048f3 [FrameworkBundle] fixed broken tests 2012-12-15 17:47:55 +01:00
Fabien Potencier
aca311e077 Merge branch '2.0' into 2.1
* 2.0:
  Added comment
  [FrameworkBundle] Added tests for trusted_proxies configuration.
  [FrameworkBundle] Added a check on file mime type for CodeHelper::fileExcerpt()
  checked for a potentially missing key
  [FrameworkBundle] used the new method for trusted proxies
  remove realpath call

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php
2012-12-15 17:44:57 +01:00
Fabien Potencier
c0fc33df44 merged branch bamarni/2.0 (PR #6154)
This PR was merged into the 2.0 branch.

Commits
-------

f0743b1 Merge pull request #1 from pylebecq/2.0
555e777 [FrameworkBundle] Added tests for trusted_proxies configuration.
a0e2391 [FrameworkBundle] used the new method for trusted proxies

Discussion
----------

[FrameworkBundle] used the new method for trusted proxies

This makes the framework bundle using the new method from the request class.

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

by fabpot at 2012-12-05T10:38:20Z

As this is a sensitive issue, can you add some tests? Thanks.

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

by bamarni at 2012-12-06T13:00:24Z

Well I don't know why it fails on travis, I can't run the full test suite locally because of a segfault but ```phpunit src/Symfony/Bundle/``` marks all the tests as passing.

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

by fabpot at 2012-12-06T13:08:11Z

But it looks like the failing tests come from what you've changed.

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

by bamarni at 2012-12-06T13:29:33Z

Yes, I'm not saying it's not my fault but I can't reproduce this as locally it tells me they pass, I'll try to fix this this evening.

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

by bamarni at 2012-12-06T17:49:28Z

Apparently it fails only when running the whole testsuite, looking at other travis builds I can see this one on 2.0 : https://travis-ci.org/symfony/symfony/jobs/3495511 which fails in a similar way than here (https://travis-ci.org/symfony/symfony/jobs/3530928). Because of a place trying to access an undefined $_SERVER key : ```PHP Notice:  Undefined index: SCRIPT_NAME ...``` but I can't find where, and the stack trace references some phpunit classes.

I'd be happy if someone could give me some pointers in here as I don't have any clue about how to fix this..

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

by bamarni at 2012-12-06T18:00:57Z

As a consulsion I'd say I can't run the whole testsuite locally (it fails even when I revert my commit), so there is no reliable way for me to fix this, if anyone is up for continuing this feel free.

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

by fabpot at 2012-12-11T09:47:48Z

@bamarni Can you just update this PR with the code change and no tests at all? I will then finish the PR. Thanks.

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

by bamarni at 2012-12-11T16:58:17Z

@fabpot: thanks for helping me out on this, hope you won't run into the same issue!
2012-12-15 17:43:45 +01:00
Fabien Potencier
021de7270a merged branch drak/frameworktestsession (PR #6369)
This PR was merged into the 2.1 branch.

Commits
-------

54d3f81 [FrameworkBundle] Fixed logic under test environment.

Discussion
----------

[FrameworkBundle] Fixed logic under test environment.

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

Please note the travis build failed on some Forms stuff which is nothing to do with this PR.
2012-12-15 17:25:40 +01:00
Drak
54d3f814ec [FrameworkBundle] Fixed logic under test environment. 2012-12-15 15:16:34 +00:00
Fabien Potencier
04d95a5bee [Yaml] tweaked phpdoc (closes #6275) 2012-12-15 14:02:34 +01:00
Fabien Potencier
a709a02538 merged branch fabpot/translation-metadata (PR #6349)
This PR was merged into the master branch.

Commits
-------

320fb6c [Translation] changed the MetadataAwareInterface method signatures
11ff433 [Translation] fixed CS in unit tests
c40db35 [Translation] removed some code that is not done anywhere else in Symfony
63719a0 [Translation] created a new interface to avoid breaking BC
23e9e65 [Translation] fixed name
5607732 [Translation] added Metadata to MessageCatalogue

Discussion
----------

[MessageCatalogue] Add Metadata to MessageCatalogue

rework of #4399

For improving the Gettext tools (PO, MO File Loader/Dumper) we need at least storage for their meta data.

This patch allows for issues below to store and process ie Po Header, Po Header Pluralisation rule.

Open
- [[WIP]: Allow Drupal to use Translate component](https://github.com/symfony/symfony/pull/4249)
- [[2.1][Translator] Symfony translation process & gettext](https://github.com/symfony/symfony/issues/4245)

Closed:
- [[Translation] Po/MoFileLoader parse plurization rules](https://github.com/symfony/symfony/pull/3023)

It has 1 TODO regarding addCatalogue: it now just override old values with new.
2012-12-15 13:49:35 +01:00
Fabien Potencier
c67ddb27b3 merged branch baldurrensch/testlistener_fix (PR #6362)
This PR was merged into the 2.1 branch.

Commits
-------

098b593 [Session] Added exception to save method
6b9ee87 [Session] Fixed a bug with the TestListener

Discussion
----------

[Session] Fixed bug with TestListener

Fixed a bug where an unstarted mock session would be emptied with a save. Here are the steps to reproduce:

Use the test client from Symfony\Bundle\FrameworkBundle\Test\WebTestCase::createClient(), and add something to its session. (I actually had it authenticate against a firewall).
Take the cookies of this first test client and add them to a second test client
Have the second test client request a URL that results in a 404
Since the 404 does not need to start the session, hence when save is called (automatically), the mock session is overwritten with an empty array. This does not happen with the other session handlers.
The added unit test in this PR shows this problem. If this PR gets accepted, will it also get merged into the 2.1.x-dev branch?

Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes (The broken test seems to be unrelated to this change)
Fixes the following tickets: -
Todo: -
License of the code: MIT
Documentation PR: -

This is a follow up PR since my original one (https://github.com/symfony/symfony/pull/6342) was against the wrong upstream branch.
2012-12-15 13:27:56 +01:00
Fabien Potencier
1de60c902c merged branch ricardclau/rename_choice_to_oneof (PR #6360)
This PR was merged into the master branch.

Commits
-------

9071676 create oneof constraint and add deprecation messages in choice, also make choice extend new oneOf constraint to avoid duplicate code

Discussion
----------

[Validator] Rename "Choice" to "OneOf"

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: #6324
Todo:
License of the code: MIT
Documentation PR: https://github.com/symfony/symfony-docs/issues/2025

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

by bschussek at 2012-12-14T18:20:56Z

Can you let `Choice` and `ChoiceValidator` extend the renamed classes? Then we avoid the code duplication. You can also remove `ChoiceValidatorTest` then.

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

by ricardclau at 2012-12-14T18:26:58Z

For sure! BTW there seems to be a problem with SF2 build when testing BR currency :S maybe it is the new ICU version supported, I guess you are aware of this but just in case!

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

by stof at 2012-12-14T21:14:04Z

the ``Choice`` constraint should trigger a ``E_USER_DEPRECATED`` in its constructor (and calling the parent constructor) as we agreed on this. The PR adding these calls everywhere is not merged yet, but it would avoid missing it when merging the PRs separately

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

by bschussek at 2012-12-14T21:19:45Z

Things missing:

* add a deprecation note to the Validator's CHANGELOG
* add a block in UPGRADE-2.2 under the Validator's "Deprecations" section that explains how to upgrade with a before/after sample
* add `trigger_error()` calls to the constructors of `Choice` and `ChoiceValidator`

See #6180 for more information about how to call `trigger_error()`.

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

by ricardclau at 2012-12-14T22:45:55Z

Sorry I was not aware of the trigger_error() agreement, absolutely +1 on it.

I hope I understood everything properly, if there is something else or some other errors please tell me!

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

by bschussek at 2012-12-15T08:46:51Z

The entry in the CHANGELOG is still missing.

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

by ricardclau at 2012-12-15T09:36:28Z

By the CHANGELOG you mean what I just added right? Hope now it is ok!

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

by bschussek at 2012-12-15T09:45:16Z

Awesome! 👍
2012-12-15 13:25:28 +01:00
Ricard Clau
9071676f0b create oneof constraint and add deprecation messages in choice, also make choice extend new oneOf constraint to avoid duplicate code 2012-12-15 10:29:01 +01:00
Fabien Potencier
e3cc337b00 merged branch colinfrei/deprecationErrors (PR #6180)
This PR was merged into the master branch.

Commits
-------

6b10550 Merge branch 'master' of github.com:symfony/symfony into deprecationErrors
1d82112 [Form] Fix two cases where deprecated methods were being used
b8cdbdc [Form] Catch deprecation errors that are caused by BC code
ebcb432 [Form] [FrameworkBundle] catch deprecation errors in tests
c21b12e [Form] handle BC use of deprecated stuff in non-test-methods.
fc2be6d [Form] catch deprecated errors in tests
800a032 [Form] replace bindRequest() with bind(), as bindRequest is deprecated
d5b2638 [Form] Trigger errors for deprecated methods in Form Component
f3d6966 [Validator] Stop using deprecated methods
d57ad32 [Form] Catch deprecation errors when using deprecated methods/classes in tests
3241157 [Validator] Trigger errors for deprecations
1f9eb7f return value of handleError
b35de9e Handle errors using a custom error handler
f49704b trigger errors for deprecated methods in HttpFoundation component

Discussion
----------

trigger_error() for deprecations

See also #6173 and #6139.

Started triggering errors in the HttpFoundation component.
It seems as if most of the time the error is just duplicating the text in the @deprecation comment.

Any opinions on if duplicating the text is acceptable, or if fetching the comment text to output the error makes sense?

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

by Seldaek at 2012-12-04T13:39:42Z

IMO it's fine to just duplicate the `@deprecated` note in the message, since anyway this code is meant to be completely deleted, this duplication should not do much harm.

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

by fabpot at 2012-12-06T08:22:21Z

@colinfrei I've merged PR #6173. Do you have time to implement the `trigger_error()` call everywhere? Thanks.

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

by colinfrei at 2012-12-06T08:36:55Z

Yep I'll finish that, probably until the beginning of next week.

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

by bschussek at 2012-12-10T10:15:12Z

Thank you for working on this!

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

by fabpot at 2012-12-12T11:08:53Z

@colinfrei: Is this PR finished? Can I merge it?

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

by colinfrei at 2012-12-12T12:09:19Z

@fabpot not quite - I lost some work due to a computer crash over the weekend. The only thing open is fixing the tests  for the Form Component and catching the cases where the Form Component intentionally uses deprecated stuff.

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

by colinfrei at 2012-12-15T07:32:28Z

@fabpot - finished adding trigger_errors and catching them in Tests and as needed.
Travis is failing, but that seems to be master being broken due to the Finder changes?

I changed a few cases where the code was using deprecated methods which wasn't necessary in my eyes, specifically   1d8211249b, 800a032f07, f3d696636a
2012-12-15 08:53:57 +01:00
Fabien Potencier
c3f1a4652f merged branch pborreli/typos-friday (PR #6364)
This PR was merged into the master branch.

Commits
-------

c84907b Merge pull request #3 from Tobion/patch-5
9ab5e4f fix typos in PhpMatcherDumper
60eeacd Fixed typos
4a073e6 [Form] Fixed duplicate case expression

Discussion
----------

Fixed Typos

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

by Tobion at 2012-12-14T22:51:05Z

👍 Thanks for fixing some of my typos.
@pborreli see pborreli/symfony#3
2012-12-15 08:49:02 +01:00
Pascal Borreli
c84907b47a Merge pull request #3 from Tobion/patch-5
fix typos in PhpMatcherDumper
2012-12-14 14:53:44 -08:00
Tobias Schultze
9ab5e4f5c7 fix typos in PhpMatcherDumper 2012-12-14 23:50:21 +01:00
Colin Frei
6b105504f4 Merge branch 'master' of github.com:symfony/symfony into deprecationErrors 2012-12-14 23:30:36 +01:00
Pascal Borreli
60eeacd2d1 Fixed typos 2012-12-14 22:27:02 +00:00
Colin Frei
1d8211249b [Form] Fix two cases where deprecated methods were being used 2012-12-14 23:17:14 +01:00
Colin Frei
b8cdbdc69f [Form] Catch deprecation errors that are caused by BC code 2012-12-14 23:16:49 +01:00
Colin Frei
ebcb432f07 [Form] [FrameworkBundle] catch deprecation errors in tests 2012-12-14 23:16:06 +01:00
Tobias Schultze
8b2c17f803 fix double-decoding in the routing system 2012-12-14 23:08:21 +01:00
Pascal Borreli
4a073e60fb [Form] Fixed duplicate case expression 2012-12-14 22:07:21 +00:00
Baldur Rensch
098b593591 [Session] Added exception to save method
A RuntimeException is thrown if there is an attempt to save the session
without it being started, or if it has already been closed.
2012-12-14 13:03:29 -08:00
Fabien Potencier
d13907bdef Merge branch '2.1'
* 2.1:
  [Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8
  [Propel1Bridge] Fix "and => &&" CS in ModelChoiceList
  [HttpKernel] Revise MongoDbProfilerStorage::write() return value
  [Session] Document Mongo|MongoClient argument type instead of "object"
  [HttpKernel] Support MongoClient and Mongo connection classes
  [Session] Support MongoClient and Mongo connection classes
  [Session] Utilize MongoDB::selectCollection()
  [Form] Fixed reverse transformation of values in DateTimeToStringTransformer

Conflicts:
	src/Symfony/Component/HttpFoundation/Session/Storage/Handler/MongoDbSessionHandler.php
	src/Symfony/Component/HttpFoundation/Tests/Session/Storage/Handler/MongoDbSessionHandlerTest.php
2012-12-14 21:34:16 +01:00
Fabien Potencier
f68ae0e57b merged branch hason/config (PR #5875)
This PR was merged into the master branch.

Commits
-------

45aab0f [Config] Added parameter to check prefix in an element or an attribute name in XmlUtils::convertDomElementToArray
7f5a7fd [DependencyInjection] Using class from Config component to loading XML files
d6f0880 [Validator] Added dependency to Config component to loading XML files
34471a6 [Routing] Using class from Config component to loading XML files
fa8b0d8 [Config] Added a utils class for XML manipulations

Discussion
----------

[Config] Added a utils class for XML manipulations

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: yes
License of the code: MIT

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

by fabpot at 2012-12-14T13:59:59Z

Looks good to me. Can you rebase on master as there is a conflict right now? Thanks.

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

by hason at 2012-12-14T14:44:11Z

Done.
2012-12-14 21:11:29 +01:00
Fabien Potencier
1017f34001 merged branch pierredup/hinclude (PR #5993)
This PR was merged into the master branch.

Commits
-------

74a8fcf [FrameworkBundle] Added support for default templates per render tag

Discussion
----------

[FrameworkBundle] Added support for default templates per render tag

This commit allows you to specify default templates per render tag when using hinclude.

E.G:
The following will use the specific default template for the render:
```` {% render "AcmeDemoBundle:Controller:action" with {}, {"standalone" : "js", "default" : "AcmeDemoBundle:Default:content.html.twig"} %}````

or if you don't want to use a template for the default content but just a string, you can do the following
```` {% render "AcmeDemoBundle:Controller:action" with {}, {"standalone" : "js", "default" : "Loading..."} %}````

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Fixes the following tickets: #3356
Todo: -
Documentation

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

by fabpot at 2012-12-14T12:25:40Z

Looks good to me. Can you add a note in the CHANGELOG of the component and send a PR on symfony/symfony-docs about this new feature? Thanks.

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

by pierredup at 2012-12-14T14:30:00Z

@fabpot done, documentation PR symfony/symfony-docs#2021
2012-12-14 21:10:00 +01:00
Fabien Potencier
563b20825f merged branch bschussek/bugfix (PR #6353)
This PR was merged into the 2.1 branch.

Commits
-------

ad29df5 [Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8

Discussion
----------

[Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8

Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: #6351, see comments in b20c5ca2ef
Todo: -
License of the code: MIT
Documentation PR: -
2012-12-14 21:05:05 +01:00
Fabien Potencier
63f1f873ff merged branch rubenrua/master (PR #6361)
This PR was merged into the master branch.

Commits
-------

4c833ac Added Galician translation

Discussion
----------

[Form] [Validator] added Galician translation

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: -
2012-12-14 21:02:05 +01:00
Fabien Potencier
42adb7ade1 merged branch fabstei/update_slovak_translation (PR #6358)
This PR was merged into the master branch.

Commits
-------

8729ff8 [Validator] Updated Slovak translations (collections and cards)

Discussion
----------

[Validator] Updated Slovak translations (collections and cards)
2012-12-14 21:01:34 +01:00
Fabien Potencier
49dc8b0bf8 merged branch efeencheung/master (PR #6356)
This PR was merged into the master branch.

Commits
-------

d7db2c3 Add two zh_CN thans-unit in validators

Discussion
----------

Add 2 zh_CN thans-unit in validators

I 've added 2 zh_CN thans-unit in validators, Please review it
2012-12-14 21:01:18 +01:00
Baldur Rensch
6b9ee87b62 [Session] Fixed a bug with the TestListener
When the session is not started, the test listener would still save the
session causing the session data to be emptied.
2012-12-14 11:26:41 -08:00
rubenrua
4c833ac80e Added Galician translation 2012-12-14 19:44:04 +01:00
Bernhard Schussek
ad29df5efd [Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8 2012-12-14 19:18:27 +01:00
Fabian Steiner
8729ff886c [Validator] Updated Slovak translations (collections and cards) 2012-12-14 17:01:37 +01:00
efeen
d7db2c387a Add two zh_CN thans-unit in validators 2012-12-14 23:14:32 +08:00
Martin Hasoň
45aab0f1e0 [Config] Added parameter to check prefix in an element or an attribute name in XmlUtils::convertDomElementToArray 2012-12-14 15:34:03 +01:00
Martin Hasoň
7f5a7fd432 [DependencyInjection] Using class from Config component to loading XML files 2012-12-14 15:34:01 +01:00
Martin Hasoň
d6f08809dd [Validator] Added dependency to Config component to loading XML files 2012-12-14 15:33:59 +01:00
Martin Hasoň
34471a636a [Routing] Using class from Config component to loading XML files 2012-12-14 15:33:56 +01:00
Martin Hasoň
fa8b0d82f1 [Config] Added a utils class for XML manipulations 2012-12-14 15:29:59 +01:00