Commit Graph

1069 Commits

Author SHA1 Message Date
Fabien Potencier
40d256e058 Merge remote branch 'kriswallsmith/kernel/bundle-extension'
* kriswallsmith/kernel/bundle-extension:
  [HttpKernel] added check of default extension alias convention
  [AsseticBundle] coding standard and comment tweaks
  [HttpKernel] added BundleInterface::getContainerExtension() which is implicitly loaded
2011-04-28 08:48:57 +02:00
Fabien Potencier
4fb1035578 fixed Doctrine EntityType when the identifier is a string 2011-04-28 08:39:14 +02:00
Fabien Potencier
7d024125d3 [Form] fixed unit tests 2011-04-28 08:11:14 +02:00
Fabien Potencier
9e23189eb1 Merge remote branch 'Brouznouf/patch-2'
* Brouznouf/patch-2:
  [Serializer] [XmlEncoder] Add unit test for decoding / encoding root with attributes
  [Seriliazer] [XmlEncoder] Optimize conditions
  [Serializer] [XmlEncoder] Allow decoder to extract attributes in root element
2011-04-28 07:49:55 +02:00
Pascal Borreli
47948c8d2b [Form] Fixed bug creating empty "1" directory in root 2011-04-28 01:06:38 +00:00
Brouznouf
5712b3bd0e [Serializer] [XmlEncoder] Add unit test for decoding / encoding root with attributes 2011-04-27 22:16:24 +02:00
Victor Berchet
d350e01e33 File & UploadedFile tweaks 2011-04-27 09:10:41 +02:00
Fabien Potencier
00bfd10ca9 [HttpFoundation] refactored File management to be safer 2011-04-27 08:50:33 +02:00
Fabien Potencier
5bb9da4b6d [HttpFoundation] renamed getDefaultExtension() to guessExtension()
The renamed method now returns null if it cannot guess the extension. It allows
the developper to know whether the extension has been guessed or not.
2011-04-27 08:03:19 +02:00
Fabien Potencier
9f846997ef Merge remote branch 'Infranology/normalize-bools'
* Infranology/normalize-bools:
  capitalized 'boolean'
  replaced 'bool' with 'Boolean'
2011-04-27 07:48:12 +02:00
Eriksen Costa
164ce5210d capitalized 'boolean' 2011-04-27 02:35:10 -03:00
Eriksen Costa
4db0752894 replaced 'bool' with 'Boolean' 2011-04-27 02:35:03 -03:00
Fabien Potencier
aa3ec504ae removed File::getWebPath()
This has been removed for several reasons:

* the framework does not know where the document root is and should not care
* as the document root was static, it was impossible to have several document roots depending on some business rules (see next one)
* sometimes, the document root is not under the web root directory (so the logic of getWebPath() is not always correct)
* the feature was not used anywhere in the core
2011-04-27 06:49:05 +02:00
Kris Wallsmith
e726cdd917 changed some skipped tests to incomplete 2011-04-26 07:22:22 -07:00
Fabien Potencier
175f944f93 [DependencyInjection] added NonExistentParameterException that indicates where a non-existent parameter is being used 2011-04-26 12:36:25 +02:00
Fabien Potencier
fefee0d5e5 [Routing] fixed URL generation when an optional variable value is 0 2011-04-26 09:50:57 +02:00
Fabien Potencier
035afc1f4e [Routing] fixed regression in Routing matching algorithm 2011-04-26 09:01:25 +02:00
Fabien Potencier
3cd0a4d2d2 [ClassLoader] fixed CS 2011-04-26 07:07:52 +02:00
Kris Wallsmith
7a7b448680 [HttpKernel] added BundleInterface::getContainerExtension() which is implicitly loaded 2011-04-25 21:12:35 -07:00
Dustin Whittle
f86bab78ff [Classloader] Fixed tests teardown when apc is not available 2011-04-25 16:12:36 -07:00
Fabien Potencier
7c95bda751 [Routing] simplified route compiler 2011-04-25 12:38:20 +02:00
Fabien Potencier
889c422d6e Merge remote branch 'igorw/ipv6'
* igorw/ipv6:
  [HttpFoundation] minor optimization
  minor adjustments suggested by vicb
  [HttpFoundation] IPv6 support for RequestMatcher
  [HttpFoundation] refactor RequestMatcherTest to use dataProvider
  [Validator] use full iPv6 regex
  [Validator] add IPv6 support to UrlValidator
  [HttpFoundation] add IPv6 support to Request
  [HttpFoundation] test Request::create with an IP as host name
  [HttpFoundation] refactor Request::getClientIp test
2011-04-24 22:04:25 +02:00
Fabien Potencier
36a63be0a5 Merge remote branch 'dustinwhittle/master'
* dustinwhittle/master:
  [Classloader] Added phpdoc with example usage + refactored unit tests fixtures
  [Classloader] Refactored ApcUniversalClassLoader to use setUp() to detect APC
  [Classloader] Fixed typo + coding standards in ApcUniversalClassLoader test
  [Classloader] Fixed APC class loader + added unit tests
2011-04-24 22:02:59 +02:00
Fabien Potencier
2f3ddb88ef Merge remote branch 'bschussek/form'
* bschussek/form:
  [Form] Automatically setting "data_class" option if objects are passed at the creation of a form
  [Form] Improved the way passed data is handled in FormFactory
  [Form] Simplified FileType code
  [HttpFoundation] TemporaryStorage automatically creates the directory if it doesn't exist yet
  [Form] Changed FormBuilder::build() to FormBuilder::create(). You hvae to pass the resulting builder to FormBuilder::add() manually now
  [Form] Added FieldTypeValidatorExtension and fixed FQCN of DelegatingValidator
2011-04-24 21:53:24 +02:00
Dustin Whittle
e8bb64c17c [Classloader] Added phpdoc with example usage + refactored unit tests fixtures 2011-04-24 07:00:27 -07:00
Dustin Whittle
29802faef4 [Classloader] Refactored ApcUniversalClassLoader to use setUp() to detect APC 2011-04-24 07:00:26 -07:00
Dustin Whittle
1f3a968ef2 [Classloader] Fixed typo + coding standards in ApcUniversalClassLoader test 2011-04-24 07:00:26 -07:00
Dustin Whittle
dbb5ca459d [Classloader] Fixed APC class loader + added unit tests 2011-04-24 07:00:26 -07:00
Fabien Potencier
4ed8d4f6b5 [Routing] fixed URL generation when a non-optional variable is empty 2011-04-24 13:06:02 +02:00
Bernhard Schussek
675e5ded9e [Form] Changed FormBuilder::build() to FormBuilder::create(). You hvae to pass the resulting builder to FormBuilder::add() manually now
$builder->add(
    $builder->create('child', 'form')
        ->add('foo', 'text')
        ->add('bar', 'text')
);
2011-04-24 12:08:50 +02:00
Fabien Potencier
8eb1dfc6a0 [Translation] forced translated id to strings 2011-04-24 09:42:41 +02:00
Fabien Potencier
b906cb59b8 Merge remote branch 'lsmith77/getAllPrevious'
* lsmith77/getAllPrevious:
  renamed getPreviouses() to getAllPrevious
2011-04-24 08:46:54 +02:00
Ryan Weaver
af8aad9c34 [Form] Throwing exception for invalid "input" type of DateType
Also fixed typo in test of previous commit
2011-04-23 20:36:40 -05:00
Ryan Weaver
66cc555bb1 [Form] Tweak to FileTypeTest to avoid warning 2011-04-23 19:47:14 -05:00
Ryan Weaver
78b2062c5e [Form] Adding an exception for an invalid widget option in DateType 2011-04-23 19:42:40 -05:00
Lukas Kahwe Smith
fd97c0caca renamed getPreviouses() to getAllPrevious 2011-04-24 01:08:15 +02:00
Fabien Potencier
81deedfc1b [Form] fixed unit tests 2011-04-23 22:17:51 +02:00
Fabien Potencier
8b74c6eb9c [DomCrawler] refactored URLs management in Link and Form 2011-04-23 21:45:44 +02:00
Lukas Kahwe Smith
d9491a743e removed support for interface injection as well as all relevant tests 2011-04-23 11:42:31 +02:00
Fabien Potencier
9a4da005a2 Merge remote branch 'bschussek/form-extensions'
* bschussek/form-extensions:
  [Form] Refactored code from CoreExtension to new ValidatorExtension
  [Form] Added FormTypeExtensionInterface
  [Form] Reorganized code into "form extensions"
2011-04-23 09:11:25 +02:00
Pascal Borreli
df3947019e [HttpFoundation][Windows] Fixed test after removal of realpath 03bb3580a6 2011-04-22 20:49:07 +00:00
Bernhard Schussek
6f1bc356a8 [Form] Refactored code from CoreExtension to new ValidatorExtension
CoreExtension is now independent of the Symfony2 validator.
2011-04-22 19:38:21 +02:00
Bernhard Schussek
1ce2db87e2 [Form] Added FormTypeExtensionInterface
With implementations of this interface, existing types can be amended.
The Csrf extension, for example, now contains a class FormTypeCsrfExtension
that adds CSRF capabilities to the "form" type.

To register new type extensions in the DIC, tag them with "form.type_extension"
and the name of the extended type as alias.
2011-04-22 19:24:38 +02:00
Bernhard Schussek
54e66c518f [Form] Reorganized code into "form extensions"
The extension classes are now the only constructor argument of the FormFactory class. They replace the existing "type loader" classes.

    new FormFactory(array(
        new CoreExtension($validator, $storage),
        new CsrfExtension($csrfProvider),
        new DoctrineOrmExtension($em),
    ));

Together with a few upcoming commits this mechanism will make

 * extension of the form framework in bundles and
 * usage of the forms outside of Symfony2

much easier.
2011-04-22 17:41:21 +02:00
Igor Wiedler
9ae5023a70 [HttpFoundation] IPv6 support for RequestMatcher 2011-04-22 17:37:22 +02:00
Igor Wiedler
5a80c2ff17 [HttpFoundation] refactor RequestMatcherTest to use dataProvider 2011-04-22 17:07:57 +02:00
Igor Wiedler
afcdbf8b79 [Validator] add IPv6 support to UrlValidator 2011-04-22 17:07:44 +02:00
Igor Wiedler
82699c5a98 [HttpFoundation] add IPv6 support to Request 2011-04-22 17:07:44 +02:00
Igor Wiedler
18e9268112 [HttpFoundation] test Request::create with an IP as host name 2011-04-22 17:07:35 +02:00
Igor Wiedler
7815bbf3ea [HttpFoundation] refactor Request::getClientIp test 2011-04-22 17:07:24 +02:00