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/src/Symfony/Component
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
..
BrowserKit Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
ClassLoader Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
Config fixed CS 2012-12-11 11:40:22 +01:00
Console [Console] Add support for parsing terminal width/height on localized windows, fixes #5742 2012-12-13 18:42:00 +01:00
CssSelector Merge branch '2.0' into 2.1 2012-12-11 11:33:11 +01:00
DependencyInjection Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
DomCrawler Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
EventDispatcher Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
Filesystem fixed CS 2012-12-11 11:40:22 +01:00
Finder Revert "merged branch gajdaw/finder_splfileinfo_fpassthu (PR #4751)" (closes #6224) 2012-12-10 13:46:54 +01:00
Form [Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8 2012-12-14 19:18:27 +01:00
HttpFoundation [Session] Added exception to save method 2012-12-14 13:03:29 -08:00
HttpKernel [HttpKernel] Revise MongoDbProfilerStorage::write() return value 2012-12-13 16:41:47 -05:00
Locale fixed CS 2012-12-11 11:40:22 +01:00
OptionsResolver Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
Process fixed CS 2012-12-11 11:40:22 +01:00
Routing fixed CS 2012-12-11 11:40:22 +01:00
Security fixed CS 2012-12-11 11:40:22 +01:00
Serializer - Test undefined index # 2012-12-12 18:17:16 +01:00
Templating Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
Translation Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00
Validator Update src/Symfony/Component/Validator/Resources/translations/validators.pl.xlf 2012-12-12 14:03:58 +01:00
Yaml Removed useless branch alias for dev-master in composer.json 2012-12-06 11:00:55 +01:00