Commit Graph

25699 Commits

Author SHA1 Message Date
Christian Flothmann
952bf010f2 [Guard] fix minimum required Seucirty Http version 2016-03-25 13:06:35 +01:00
Fabien Potencier
697bac9bf2 feature #18197 Make Request::isFromTrustedProxy() public. (Peter Bex)
This PR was merged into the 3.1-dev branch.

Discussion
----------

Make Request::isFromTrustedProxy() public.

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

When adding custom headers to your proxy (in our particular case, a `X-Base-Url` header, but it could be anything), it is necessary to be able to tell whether the request came from a trusted proxy or not. Unfortunately, currently the `isFromTrustedProxy()` method is private, which means you'll need to subclass `Request` and add your own *differently named* method just to be able to access this information.

This functionality is pretty straightforward, and I don't see a reason to keep this method private so this a trivial pull request to make it public (and it adds a comment so it'll show up in the API docs with proper documentation).

Commits
-------

286f64f Make Request::isFromTrustedProxy() public.
2016-03-25 12:38:37 +01:00
Nicolas Grekas
ae9bae7e16 [phpunit] disable prophecy 2016-03-25 10:58:58 +01:00
Nicolas Grekas
37dd041cda minor #18306 [2.3] fix mocks (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] fix mocks

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

* fix a typo in a method name (`setResponse` instead of `seetResopnse`)
* fix mocking a method that is not part of the `DomainObjectInterface`

Commits
-------

c211523 fix mocks
2016-03-25 10:57:13 +01:00
Christian Flothmann
c211523f6e fix mocks
* fix a typo in a method name (`setResponse` instead of `seetResopnse`)
* fix mocking a method that is not part of the `DomainObjectInterface`
2016-03-25 10:45:26 +01:00
Tobias Schultze
3598105da9 Merge branch '3.0' 2016-03-25 02:52:00 +01:00
Tobias Schultze
8529f190fb [Form] remove irrelevant doc after 3.0 merge 2016-03-25 02:50:54 +01:00
Tobias Schultze
fe36f04889 Merge branch '2.8' into 3.0 2016-03-25 02:41:20 +01:00
Tobias Schultze
a8843132b8 Merge branch '2.7' into 2.8 2016-03-25 02:40:30 +01:00
Tobias Schultze
0cd725ea42 Merge branch '2.3' into 2.7 2016-03-25 02:39:14 +01:00
Tobias Schultze
43df701103 minor #18303 [Form] Fix Forms docblock to use FQCN (HeahDude)
This PR was merged into the 2.8 branch.

Discussion
----------

[Form] Fix `Forms` docblock to use FQCN

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

Commits
-------

df61aab [Form] Fix `Forms` docblock to use FQCN
2016-03-25 02:32:07 +01:00
Tobias Schultze
0839df5b70 minor #18302 [Form] Fix FormBuilderInterface docblocks (HeahDude)
This PR was merged into the 3.0 branch.

Discussion
----------

[Form] Fix `FormBuilderInterface` docblocks

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

Commits
-------

67458d8 [Form] Fix `FormBuilderInterface` docblocks
2016-03-25 02:26:45 +01:00
Tobias Schultze
90ece1cf5c minor #18299 [Form] Remove unused legacy code in ChoiceType (HeahDude)
This PR was merged into the 3.0 branch.

Discussion
----------

[Form] Remove unused legacy code in `ChoiceType`

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

Commits
-------

8af78e9 [Form] Remove unused legacy code in `ChoiceType`
2016-03-25 02:25:21 +01:00
Jules Pietri
df61aabaa7 [Form] Fix Forms docblock to use FQCN 2016-03-24 20:57:49 +01:00
Jules Pietri
67458d8cf5 [Form] Fix FormBuilderInterface docblocks 2016-03-24 20:40:46 +01:00
Jules Pietri
8af78e9f9b [Form] Remove unused legacy code in ChoiceType 2016-03-24 20:00:16 +01:00
Christian Flothmann
2066fc03c7 [Validator] do not treat payload as callback 2016-03-24 16:03:49 +01:00
Tobias Schultze
058dee70c6 minor #18293 [FrameworkBundle 2.7+] Removed unused variables (iltar)
This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle 2.7+] Removed unused variables

| Q             | A
| ------------- | ---
| Branch?       | 2.7, can be merged upwards
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | ~
| License       | MIT
| Doc PR        | ~

I noticed some unused variables in the Framework Extension. I did a project inspection in phpstorm and I found nothing else. Hence I submit this PR to make it consistent again.

Commits
-------

9fea1ee Removed unused variables
2016-03-24 14:05:39 +01:00
Iltar van der Berg
9fea1ee4f4 Removed unused variables 2016-03-24 12:33:34 +01:00
Tobias Schultze
89f1c35e58 minor #18291 Fix copy-paste in PHPDoc comment text (guilliamxavier)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix copy-paste in PHPDoc comment text

| Q             | A
| ------------- | ---
| Branch?       | 2.3+ (actually all branches from 2.0)
| License       | MIT

In http://api.symfony.com/2.3/Symfony/Component/Form/DataTransformerInterface.html, compare the documentation (*emphasis* mine) respectively for `transform` and for `reverseTransform`:

> Usually this will be *NULL*, but […] other empty values are possible as well (such as *empty strings*).
> Usually this will be *an empty string*, but […] other empty values are possible as well (such as *empty strings*).

This PR corrects the repetition in the latter, giving symmetry:

> Usually this will be *NULL*, but […] other empty values are possible as well (such as *empty strings*).
> Usually this will be *an empty string*, but […] other empty values are possible as well (such as *NULL*).

_Note:_ For now I just changed `empty strings` to `NULL`, which is 9 characters shorter, should I also reformat the affected comment paragraph so that this line and the subsequent ones fill up to 80 columns (as was the case before the change, and is for `transform`)?

Commits
-------

3f6e37e Fix copy-paste in PHPDoc comment text
2016-03-24 12:17:56 +01:00
Tobias Schultze
d31d92ef67 minor #18286 [2.7] fix mocking of some methods (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[2.7] fix mocking of some methods

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | items 6 and 8 of https://github.com/sebastianbergmann/phpunit-mock-objects/issues/299#issuecomment-200443756
| License       | MIT
| Doc PR        |

Commits
-------

a45b93d [2.7] fix mocking of some methods
2016-03-24 11:22:08 +01:00
Guilliam Xavier
3f6e37efe6 Fix copy-paste in PHPDoc comment text 2016-03-24 10:50:31 +01:00
Christian Flothmann
a45b93d423 [2.7] fix mocking of some methods 2016-03-24 10:06:43 +01:00
Tobias Schultze
e375161784 minor #18284 [2.3] fix mocking of some methods (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] fix mocking of some methods

| Q             | A
| ------------- | ---
| Branch?       | 2.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? |no
| Tests pass?   | yes
| Fixed tickets | items 3, 4, 5, and 7 of https://github.com/sebastianbergmann/phpunit-mock-objects/issues/299#issuecomment-200443756
| License       | MIT
| Doc PR        |

Commits
-------

542cf6b [2.3] fix mocking of some methods
2016-03-24 00:07:02 +01:00
Tobias Schultze
06b1e5d38b minor #18287 [3.0] fix mocking of some methods (xabbuh)
This PR was merged into the 3.0 branch.

Discussion
----------

[3.0] fix mocking of some methods

| Q             | A
| ------------- | ---
| Branch?       | 3.0
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | items 1 and 2 of https://github.com/sebastianbergmann/phpunit-mock-objects/issues/299#issuecomment-200443756
| License       | MIT
| Doc PR        |

Commits
-------

07308e9 [3.0] fix mocking of some methods
2016-03-23 23:48:01 +01:00
Christian Flothmann
07308e9322 [3.0] fix mocking of some methods 2016-03-23 23:25:51 +01:00
Christian Flothmann
542cf6b046 [2.3] fix mocking of some methods 2016-03-23 22:36:43 +01:00
Christian Flothmann
243e59c108 Merge branch '3.0'
* 3.0:
  fix controller tests
  move test methods to test case class
2016-03-23 21:25:59 +01:00
Christian Flothmann
abbc7e3f86 minor #18282 fix controller tests (xabbuh)
This PR was merged into the 3.0 branch.

Discussion
----------

fix controller tests

| Q             | A
| ------------- | ---
| Branch?       | 3.0
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | items 9 to 12 from https://github.com/sebastianbergmann/phpunit-mock-objects/issues/299#issuecomment-200443756
| License       | MIT
| Doc PR        |

Add missing public method stubs to `TestController` (all methods in the base `Controller` class from the FrameworkBundle are `protected` since Symfony 3.0).

Commits
-------

fb963d2 fix controller tests
2016-03-23 21:21:31 +01:00
Christian Flothmann
fb963d27c9 fix controller tests
Add missing public method stubs to `TestController` (all methods in the
base `Controller` class from the FrameworkBundle are `protected` since
Symfony 3.0).
2016-03-23 21:13:13 +01:00
Christian Flothmann
239d546db3 Merge branch '2.8' into 3.0
* 2.8:
  move test methods to test case class
2016-03-23 21:03:51 +01:00
Christian Flothmann
d2b0ebc941 Merge branch '2.7' into 2.8
* 2.7:
  move test methods to test case class
2016-03-23 20:59:19 +01:00
Nicolas Grekas
bd6d9bb1c2 minor #18283 [FrameworkBundle] move test methods to test case class (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle] move test methods to test case class

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

Commits
-------

8188653 move test methods to test case class
2016-03-23 20:29:17 +01:00
Christian Flothmann
81886530c7 move test methods to test case class 2016-03-23 19:17:25 +01:00
Nicolas Grekas
abb8d6486a bug #18248 Fast multiple setEx with the pipeline transcation (RedisAdapter::doSave) (masterklavi)
This PR was squashed before being merged into the 3.1-dev branch (closes #18248).

Discussion
----------

Fast multiple setEx with the pipeline transcation (RedisAdapter::doSave)

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

Commits
-------

e132763 Fast multiple setEx with the pipeline transcation (RedisAdapter::doSave)
2016-03-23 18:34:09 +01:00
Masterklavi
e132763f55 Fast multiple setEx with the pipeline transcation (RedisAdapter::doSave) 2016-03-23 18:33:57 +01:00
Nicolas Grekas
c7493f5649 minor #18278 use class constants instead of FQCN strings (xabbuh)
This PR was merged into the 3.1-dev branch.

Discussion
----------

use class constants instead of FQCN strings

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/18211#discussion_r56491661
| License       | MIT
| Doc PR        |

Commits
-------

d4ec7dd use class constants instead of FQCN strings
2016-03-23 18:29:10 +01:00
Nicolas Grekas
9e32a4d2c3 Merge branch '3.0'
* 3.0:
  [ci] Tweak scripts

Conflicts:
	appveyor.yml
2016-03-23 18:20:53 +01:00
Christian Flothmann
d4ec7dd845 use class constants instead of FQCN strings 2016-03-23 18:13:33 +01:00
Nicolas Grekas
96eacb4884 Merge branch '2.8' into 3.0
* 2.8:
  [ci] Tweak scripts
2016-03-23 18:06:38 +01:00
Fabien Potencier
434a2f51e2 feature #18211 [Security] Use auth trust resolver to determine anonymous in ContextListener (WouterJ)
This PR was squashed before being merged into the 3.1-dev branch (closes #18211).

Discussion
----------

[Security] Use auth trust resolver to determine anonymous in ContextListener

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

There is a nice class in Symfony that is used to check whether a token is anonymously: `AuthenticationTrustResolver`. However, its logic was still hard coded in the `ContextListener`, making it impossible to customize it (e.g. using another anonymous token class). I think it makes lots of sense to use the dedicated class.

Commits
-------

ab5578e [Security] Use auth trust resolver to determine anonymous in ContextListener
2016-03-23 10:01:36 -07:00
WouterJ
ab5578e5ac [Security] Use auth trust resolver to determine anonymous in ContextListener 2016-03-23 10:01:34 -07:00
Nicolas Grekas
a18812563f Merge branch '2.7' into 2.8
* 2.7:
  [ci] Tweak scripts

Conflicts:
	appveyor.yml
2016-03-23 17:56:49 +01:00
Nicolas Grekas
505bf4db5d Merge branch '2.3' into 2.7
* 2.3:
  [ci] Tweak scripts
2016-03-23 17:16:30 +01:00
Nicolas Grekas
a5965fb23b minor #18276 [ci] Tweak scripts (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[ci] Tweak scripts

| Q             | A
| ------------- | ---
| Branch?       | 2.3
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/sebastianbergmann/phpunit-mock-objects/issues/299
| License       | MIT
| Doc PR        | -

Commits
-------

82c6bed [ci] Tweak scripts
2016-03-23 17:16:02 +01:00
Nicolas Grekas
82c6bed6b0 [ci] Tweak scripts 2016-03-23 17:07:44 +01:00
Nicolas Grekas
1b216477ee feature #18232 [Bridge\PhpUnit] Add "disabled" mode to SYMFONY_DEPRECATIONS_HELPER (nicolas-grekas)
This PR was merged into the 3.1-dev branch.

Discussion
----------

[Bridge\PhpUnit] Add "disabled" mode to SYMFONY_DEPRECATIONS_HELPER

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

See https://github.com/symfony/symfony/pull/18232/files?w=1

Because we keep adding features to the bridge, so that one could want some features but not the deprecations helper.
In weak mode, this PR also disables colors.
Fetching the SYMFONY_DEPRECATIONS_HELPER env var is also done lazily to workaround old phpunit versions affected by sebastianbergmann/phpunit#1216

Commits
-------

64fe539 [Bridge\PhpUnit] Add "disabled" mode to SYMFONY_DEPRECATIONS_HELPER
2016-03-23 14:49:35 +01:00
Nicolas Grekas
64fe5392f9 [Bridge\PhpUnit] Add "disabled" mode to SYMFONY_DEPRECATIONS_HELPER 2016-03-23 14:47:06 +01:00
Nicolas Grekas
a4af637317 Merge branch '3.0'
* 3.0:
  Fix backport
2016-03-23 14:46:29 +01:00
Nicolas Grekas
37a75f463d Merge branch '2.8' into 3.0
* 2.8:
  Fix backport
2016-03-23 14:46:08 +01:00