Merge branch 'legacy27' into legacy-master

* legacy27:
  [2.7] add @group legacy
  [2.6] add @group legacy
  [2.3] add @group legacy

Conflicts:
	src/Symfony/Bridge/Doctrine/Tests/Validator/Constraints/LegacyUniqueEntityValidatorLegacyApiTest.php
	src/Symfony/Bridge/Twig/Tests/Extension/AssetExtensionTest.php
	src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Compiler/LegacyTemplatingAssetHelperPassTest.php
	src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/ConfigurationTest.php
	src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/FrameworkExtensionTest.php
	src/Symfony/Bundle/FrameworkBundle/Tests/Templating/Helper/AssetsHelper.php
	src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/TwigExtensionTest.php
	src/Symfony/Bundle/TwigBundle/Tests/TokenParser/LegacyRenderTokenParserTest.php
	src/Symfony/Component/ClassLoader/Tests/ApcClassLoaderTest.php
	src/Symfony/Component/ClassLoader/Tests/LegacyUniversalClassLoaderTest.php
	src/Symfony/Component/Console/Tests/Command/CommandTest.php
	src/Symfony/Component/Console/Tests/Helper/LegacyDialogHelperTest.php
	src/Symfony/Component/Console/Tests/Helper/LegacyProgressHelperTest.php
	src/Symfony/Component/Console/Tests/Helper/LegacyTableHelperTest.php
	src/Symfony/Component/EventDispatcher/Tests/AbstractEventDispatcherTest.php
	src/Symfony/Component/EventDispatcher/Tests/EventTest.php
	src/Symfony/Component/Form/Tests/AbstractLayoutTest.php
	src/Symfony/Component/Form/Tests/Extension/HttpFoundation/EventListener/LegacyBindRequestListenerTest.php
	src/Symfony/Component/HttpFoundation/Tests/Session/Flash/FlashBagTest.php
	src/Symfony/Component/HttpKernel/Tests/KernelTest.php
	src/Symfony/Component/OptionsResolver/Tests/LegacyOptionsResolverTest.php
	src/Symfony/Component/OptionsResolver/Tests/LegacyOptionsTest.php
	src/Symfony/Component/Routing/Tests/Annotation/RouteTest.php
	src/Symfony/Component/Routing/Tests/Generator/UrlGeneratorTest.php
	src/Symfony/Component/Routing/Tests/Loader/XmlFileLoaderTest.php
	src/Symfony/Component/Routing/Tests/Loader/YamlFileLoaderTest.php
	src/Symfony/Component/Routing/Tests/Matcher/Dumper/LegacyApacheMatcherDumperTest.php
	src/Symfony/Component/Routing/Tests/Matcher/LegacyApacheUrlMatcherTest.php
	src/Symfony/Component/Routing/Tests/RouteTest.php
	src/Symfony/Component/Templating/Tests/Helper/LegacyAssetsHelperTest.php
	src/Symfony/Component/Templating/Tests/Helper/LegacyCoreAssetsHelperTest.php
	src/Symfony/Component/Yaml/Tests/YamlTest.php
This commit is contained in:
Nicolas Grekas 2015-03-13 19:00:11 +01:00
commit 1f0640aba4
103 changed files with 314 additions and 3 deletions

View File

@ -267,6 +267,9 @@ class GenericEntityChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertEquals(array(1, 2), $choiceList->getValuesForChoices(array($item1, $item2)));
}
/**
* @group legacy
*/
public function testLegacyInitShorthandEntityName()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -21,6 +21,9 @@ class UnloadedEntityChoiceListSingleIntIdTest extends AbstractEntityChoiceListSi
$this->markTestSkipped('Non-existing values are not detected for unloaded choice lists.');
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValuesIgnoresNonExistingValues()
{
$this->markTestSkipped('Non-existing values are not detected for unloaded choice lists.');

View File

@ -66,7 +66,10 @@ abstract class AbstractDescriptorTest extends \PHPUnit_Framework_TestCase
return $this->getContainerBuilderDescriptionTestData(ObjectsProvider::getContainerBuilders());
}
/** @dataProvider provideLegacySynchronizedServiceDefinitionTestData */
/**
* @dataProvider provideLegacySynchronizedServiceDefinitionTestData
* @group legacy
*/
public function testLegacyDescribeSynchronizedServiceDefinition(Definition $definition, $expectedDescription)
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -15,6 +15,9 @@ use Symfony\Component\DependencyInjection\Reference;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Bundle\FrameworkBundle\DependencyInjection\Compiler\FragmentRendererPass;
/**
* @group legacy
*/
class LegacyFragmentRendererPassTest extends \PHPUnit_Framework_TestCase
{
protected function setUp()

View File

@ -304,6 +304,9 @@ abstract class FrameworkExtensionTest extends TestCase
$this->assertEquals(array(Validation::API_VERSION_2_5_BC), $calls[6][1]);
}
/**
* @group legacy
*/
public function testLegacyFullyConfiguredValidationService()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -466,6 +469,9 @@ abstract class FrameworkExtensionTest extends TestCase
$this->assertFalse($container->getParameter('form.type_extension.csrf.enabled'));
}
/**
* @group legacy
*/
public function testLegacyFormCsrfFieldNameCanBeSetUnderCsrfSettings()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -476,6 +482,9 @@ abstract class FrameworkExtensionTest extends TestCase
$this->assertEquals('_custom', $container->getParameter('form.type_extension.csrf.field_name'));
}
/**
* @group legacy
*/
public function testLegacyFormCsrfFieldNameUnderFormSettingsTakesPrecedence()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -15,6 +15,9 @@ use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
use Symfony\Bundle\FrameworkBundle\Fragment\ContainerAwareHIncludeFragmentRenderer;
use Symfony\Component\HttpFoundation\Request;
/**
* @group legacy
*/
class LegacyContainerAwareHIncludeFragmentRendererTest extends TestCase
{
public function testRender()

View File

@ -26,6 +26,9 @@ class GlobalVariablesTest extends TestCase
$this->globals = new GlobalVariables($this->container);
}
/**
* @group legacy
*/
public function testLegacyGetSecurity()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -40,6 +40,9 @@ class SecurityDataCollectorTest extends \PHPUnit_Framework_TestCase
$this->assertEmpty($collector->getUser());
}
/**
* @group legacy
*/
public function testLegacyCollectWhenAuthenticationTokenIsNull()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -490,6 +490,9 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
}
}
/**
* @group legacy
*/
public function testLegacyAsText()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -501,6 +504,9 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext2.txt', $this->normalizeLineBreaks($application->asText('foo')), '->asText() returns a text representation of the application');
}
/**
* @group legacy
*/
public function testLegacyAsXml()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -373,6 +373,9 @@ class InputDefinitionTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('foo1 ... [fooN]', $definition->getSynopsis(), '->getSynopsis() returns a synopsis of arguments and options');
}
/**
* @group legacy
*/
public function testLegacyAsText()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -390,6 +393,9 @@ class InputDefinitionTest extends \PHPUnit_Framework_TestCase
$this->assertStringEqualsFile(self::$fixtures.'/definition_astext.txt', $definition->asText(), '->asText() returns a textual representation of the InputDefinition');
}
/**
* @group legacy
*/
public function testLegacyAsXml()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -41,6 +41,9 @@ class StringInputTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('bar', $input->getOption('foo'));
}
/**
* @group legacy
*/
public function testLegacyInputOptionDefinitionInConstructor()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -354,6 +354,9 @@ class ErrorHandlerTest extends \PHPUnit_Framework_TestCase
}
}
/**
* @group legacy
*/
public function testLegacyInterface()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -34,8 +34,8 @@ class ClassNotFoundFatalErrorHandlerTest extends \PHPUnit_Framework_TestCase
}
/**
* @group legacy
* @dataProvider provideLegacyClassNotFoundData
* @group legacy
*/
public function testLegacyHandleClassNotFound($error, $translatedMessage, $autoloader)
{

View File

@ -52,6 +52,7 @@ class CheckDefinitionValidityPassTest extends \PHPUnit_Framework_TestCase
/**
* @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException
* @group legacy
*/
public function testLegacyProcessDetectsBothFactorySyntaxesUsed()
{

View File

@ -684,6 +684,9 @@ class ContainerBuilderTest extends \PHPUnit_Framework_TestCase
$this->assertEquals($a, $container->get('a'));
}
/**
* @group legacy
*/
public function testLegacySetOnSynchronizedService()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -703,6 +706,9 @@ class ContainerBuilderTest extends \PHPUnit_Framework_TestCase
$this->assertSame($baz, $container->get('bar')->getBaz());
}
/**
* @group legacy
*/
public function testLegacySynchronizedServiceWithScopes()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -51,6 +51,7 @@ class DefinitionDecoratorTest extends \PHPUnit_Framework_TestCase
/**
* @dataProvider provideLegacyPropertyTests
* @group legacy
*/
public function testLegacySetProperty($property, $changeKey)
{

View File

@ -166,6 +166,7 @@ class DefinitionTest extends \PHPUnit_Framework_TestCase
/**
* @covers Symfony\Component\DependencyInjection\Definition::setSynchronized
* @covers Symfony\Component\DependencyInjection\Definition::isSynchronized
* @group legacy
*/
public function testLegacySetIsSynchronized()
{

View File

@ -23,6 +23,9 @@ class GraphvizDumperTest extends \PHPUnit_Framework_TestCase
self::$fixturesPath = __DIR__.'/../Fixtures/';
}
/**
* @group legacy
*/
public function testLegacyDump()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -124,6 +124,9 @@ class PhpDumperTest extends \PHPUnit_Framework_TestCase
}
}
/**
* @group legacy
*/
public function testLegacySynchronizedServices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -47,6 +47,9 @@ class XmlDumperTest extends \PHPUnit_Framework_TestCase
$this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters');
}
/**
* @group legacy
*/
public function testLegacyAddService()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -40,6 +40,9 @@ class YamlDumperTest extends \PHPUnit_Framework_TestCase
$this->assertStringEqualsFile(self::$fixturesPath.'/yaml/services8.yml', $dumper->dump(), '->dump() dumps parameters');
}
/**
* @group legacy
*/
public function testLegacyAddService()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -14,6 +14,9 @@ namespace Symfony\Component\DependencyInjection\Tests;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Reference;
/**
* @group legacy
*/
class LegacyContainerBuilderTest extends \PHPUnit_Framework_TestCase
{
protected function setUp()

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\DependencyInjection\Tests;
use Symfony\Component\DependencyInjection\Definition;
/**
* @group legacy
*/
class LegacyDefinitionTest extends \PHPUnit_Framework_TestCase
{
protected function setUp()

View File

@ -191,6 +191,9 @@ class XmlFileLoaderTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('BazClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones');
}
/**
* @group legacy
*/
public function testLegacyLoadServices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -120,6 +120,9 @@ class YamlFileLoaderTest extends \PHPUnit_Framework_TestCase
$loader->load('services4_bad_import.yml');
}
/**
* @group legacy
*/
public function testLegacyLoadServices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -803,6 +803,9 @@ class CompoundFormTest extends AbstractFormTest
$this->assertEquals(array('extra' => 'data'), $form->getExtraData());
}
/**
* @group legacy
*/
public function testLegacyGetErrorsAsStringDeep()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -824,6 +827,9 @@ class CompoundFormTest extends AbstractFormTest
);
}
/**
* @group legacy
*/
public function testLegacyGetErrorsAsStringDeepWithIndentation()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -161,6 +161,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame($this->values, $this->list->getValues());
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -169,6 +172,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array($this->index1, $this->index2), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesPreservesKeys()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -177,6 +183,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array(5 => $this->index1, 8 => $this->index2), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesPreservesOrder()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -185,6 +194,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array($this->index2, $this->index1), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesIgnoresNonExistingChoices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -193,6 +205,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array($this->index1, $this->index2), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesEmpty()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -200,6 +215,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array(), $this->list->getIndicesForChoices(array()));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValues()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -209,6 +227,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array($this->index1, $this->index2), $this->list->getIndicesForValues($values));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValuesPreservesKeys()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -218,6 +239,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array(5 => $this->index1, 8 => $this->index2), $this->list->getIndicesForValues($values));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValuesPreservesOrder()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -226,6 +250,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array($this->index2, $this->index1), $this->list->getIndicesForValues($values));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValuesIgnoresNonExistingValues()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -234,6 +261,9 @@ abstract class AbstractChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array($this->index1, $this->index2), $this->list->getIndicesForValues($values));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValuesEmpty()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -57,6 +57,9 @@ class LazyChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertEquals(array(0 => new ChoiceView('a', 'a', 'A'), 2 => new ChoiceView('c', 'c', 'C')), $this->list->getRemainingViews());
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -65,6 +68,9 @@ class LazyChoiceListTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array(1, 2), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValues()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -185,6 +185,9 @@ class ObjectChoiceListTest extends AbstractChoiceListTest
);
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesWithValuePath()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -202,6 +205,9 @@ class ObjectChoiceListTest extends AbstractChoiceListTest
$this->assertSame(array($this->index1, $this->index2), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesWithValuePathPreservesKeys()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -218,6 +224,9 @@ class ObjectChoiceListTest extends AbstractChoiceListTest
$this->assertSame(array(5 => $this->index1, 8 => $this->index2), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesWithValuePathPreservesOrder()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -234,6 +243,9 @@ class ObjectChoiceListTest extends AbstractChoiceListTest
$this->assertSame(array($this->index2, $this->index1), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesWithValuePathIgnoresNonExistingChoices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -15,6 +15,9 @@ use Symfony\Component\Form\Extension\Core\ChoiceList\SimpleChoiceList;
class SimpleNumericChoiceListTest extends AbstractChoiceListTest
{
/**
* @group legacy
*/
public function testLegacyGetIndicesForChoicesDealsWithNumericChoices()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -24,6 +27,9 @@ class SimpleNumericChoiceListTest extends AbstractChoiceListTest
$this->assertSame(array(0, 1), $this->list->getIndicesForChoices($choices));
}
/**
* @group legacy
*/
public function testLegacyGetIndicesForValuesDealsWithNumericValues()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -637,6 +637,9 @@ class FormTypeTest extends BaseTypeTest
$this->assertSame('0', $view->vars['label']);
}
/**
* @group legacy
*/
public function testLegacyCanGetErrorsWhenButtonInForm()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -16,8 +16,9 @@ use Symfony\Component\Form\Extension\Csrf\CsrfProvider\DefaultCsrfProvider;
/**
* @runTestsInSeparateProcesses
* @preserveGlobalState disabled
* @group legacy
*/
class DefaultCsrfProviderTest extends \PHPUnit_Framework_TestCase
class LegacyDefaultCsrfProviderTest extends \PHPUnit_Framework_TestCase
{
protected $provider;

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\Form\Tests\Extension\Csrf\CsrfProvider;
use Symfony\Component\Form\Extension\Csrf\CsrfProvider\SessionCsrfProvider;
/**
* @group legacy
*/
class LegacySessionCsrfProviderTest extends \PHPUnit_Framework_TestCase
{
protected $provider;

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyFormValidatorLegacyApiTest extends FormValidatorTest
{

View File

@ -732,6 +732,9 @@ class SimpleFormTest extends AbstractFormTest
$this->assertSame($view, $form->createView($parentView));
}
/**
* @group legacy
*/
public function testLegacyGetErrorsAsString()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Handler;
use Symfony\Component\HttpFoundation\Session\Storage\Handler\LegacyPdoSessionHandler;
/**
* @group legacy
*/
class LegacyPdoSessionHandlerTest extends \PHPUnit_Framework_TestCase
{
private $pdo;

View File

@ -18,6 +18,9 @@ use Symfony\Component\HttpKernel\Fragment\FragmentRendererInterface;
class FragmentRendererPassTest extends \PHPUnit_Framework_TestCase
{
/**
* @group legacy
*/
public function testLegacyFragmentRedererWithoutAlias()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -24,6 +24,8 @@ class ProfilerListenerTest extends \PHPUnit_Framework_TestCase
{
/**
* Test to ensure BC without RequestStack
*
* @group legacy
*/
public function testLegacyEventsWithoutRequestStack()
{

View File

@ -234,6 +234,7 @@ abstract class AbstractProcessTest extends \PHPUnit_Framework_TestCase
/**
* @dataProvider provideLegacyInputValues
* @group legacy
*/
public function testLegacyValidInput($expected, $value)
{

View File

@ -15,6 +15,9 @@ use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorage;
use Symfony\Component\Security\Core\Authorization\AuthorizationChecker;
use Symfony\Component\Security\Core\SecurityContext;
/**
* @group legacy
*/
class LegacySecurityContextTest extends \PHPUnit_Framework_TestCase
{
private $tokenStorage;

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.4
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyUserPasswordValidatorApiTest extends UserPasswordValidatorTest
{

View File

@ -14,6 +14,9 @@ namespace Symfony\Component\Security\Tests\Core;
use Symfony\Component\Security\Core\SecurityContextInterface;
use Symfony\Component\Security\Core\Security;
/**
* @group legacy
*/
class LegacySecurityContextInterfaceTest extends \PHPUnit_Framework_TestCase
{
/**

View File

@ -99,6 +99,9 @@ class GetSetMethodNormalizerTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('bar', $obj->getBar());
}
/**
* @group legacy
*/
public function testLegacyDenormalizeOnCamelCaseFormat()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -117,6 +120,9 @@ class GetSetMethodNormalizerTest extends \PHPUnit_Framework_TestCase
$this->assertEquals(new GetSetDummy(), $this->normalizer->denormalize(null, __NAMESPACE__.'\GetSetDummy'));
}
/**
* @group legacy
*/
public function testLegacyCamelizedAttributesNormalize()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -140,6 +146,9 @@ class GetSetMethodNormalizerTest extends \PHPUnit_Framework_TestCase
));
}
/**
* @group legacy
*/
public function testLegacyCamelizedAttributesDenormalize()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -96,6 +96,9 @@ class ObjectNormalizerTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('bar', $obj->bar);
}
/**
* @group legacy
*/
public function testLegacyDenormalizeOnCamelCaseFormat()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -62,6 +62,9 @@ class PropertyNormalizerTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('bar', $obj->getBar());
}
/**
* @group legacy
*/
public function testLegacyDenormalizeOnCamelCaseFormat()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -74,6 +77,9 @@ class PropertyNormalizerTest extends \PHPUnit_Framework_TestCase
$this->assertEquals('value', $obj->getCamelCase());
}
/**
* @group legacy
*/
public function testLegacyCamelizedAttributesNormalize()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -97,6 +103,9 @@ class PropertyNormalizerTest extends \PHPUnit_Framework_TestCase
));
}
/**
* @group legacy
*/
public function testLegacyCamelizedAttributesDenormalize()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -24,6 +24,9 @@ class LoaderTest extends \PHPUnit_Framework_TestCase
$this->assertSame($logger, $loader->getLogger(), '->setLogger() sets the logger instance');
}
/**
* @group legacy
*/
public function testLegacyGetSetDebugger()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -186,6 +186,9 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
}
// BC with Symfony < 2.4
/**
* @group legacy
*/
public function testLegacySingleMethodBc()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -201,6 +204,9 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
}
// BC with Symfony < 2.4
/**
* @group legacy
*/
public function testLegacySingleMethodBcExplicitName()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -216,6 +222,9 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
}
// BC with Symfony < 2.4
/**
* @group legacy
*/
public function testLegacyMultipleMethodsBc()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -233,6 +242,9 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
}
// BC with Symfony < 2.4
/**
* @group legacy
*/
public function testLegacyMultipleMethodsBcExplicitName()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -252,6 +264,9 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
}
// BC with Symfony < 2.4
/**
* @group legacy
*/
public function testLegacySingleStaticMethodBc()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -269,6 +284,9 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
}
// BC with Symfony < 2.4
/**
* @group legacy
*/
public function testLegacySingleStaticMethodBcExplicitName()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -307,6 +325,7 @@ class CallbackValidatorTest extends AbstractConstraintValidatorTest
/**
* @expectedException \Symfony\Component\Validator\Exception\ConstraintDefinitionException
* @group legacy
*/
public function testLegacyExpectEitherCallbackOrMethods()
{

View File

@ -32,6 +32,9 @@ class GroupSequenceTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array('Group 1', 'Group 2'), $sequence->groups);
}
/**
* @group legacy
*/
public function testLegacyIterate()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -41,6 +44,9 @@ class GroupSequenceTest extends \PHPUnit_Framework_TestCase
$this->assertSame(array('Group 1', 'Group 2'), iterator_to_array($sequence));
}
/**
* @group legacy
*/
public function testLegacyCount()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -50,6 +56,9 @@ class GroupSequenceTest extends \PHPUnit_Framework_TestCase
$this->assertCount(2, $sequence);
}
/**
* @group legacy
*/
public function testLegacyArrayAccess()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -72,6 +81,7 @@ class GroupSequenceTest extends \PHPUnit_Framework_TestCase
/**
* @expectedException \Symfony\Component\Validator\Exception\OutOfBoundsException
* @group legacy
*/
public function testLegacyGetExpectsExistingKey()
{
@ -82,6 +92,9 @@ class GroupSequenceTest extends \PHPUnit_Framework_TestCase
$sequence[2];
}
/**
* @group legacy
*/
public function testLegacyUnsetIgnoresNonExistingKeys()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyAllValidatorLegacyApiTest extends AllValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyBlankValidatorLegacyApiTest extends BlankValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyCallbackValidatorLegacyApiTest extends CallbackValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyCardSchemeValidatorLegacyApiTest extends CardSchemeValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyChoiceValidatorLegacyApiTest extends ChoiceValidatorTest
{

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\Validator\Tests\Constraints;
use Symfony\Component\Validator\Validation;
/**
* @group legacy
*/
class LegacyCollectionValidatorArrayLegacyApiTest extends CollectionValidatorArrayTest
{
protected function getApiVersion()

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\Validator\Tests\Constraints;
use Symfony\Component\Validator\Validation;
/**
* @group legacy
*/
class LegacyCollectionValidatorArrayObjectLegacyApiTest extends CollectionValidatorArrayObjectTest
{
protected function getApiVersion()

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\Validator\Tests\Constraints;
use Symfony\Component\Validator\Validation;
/**
* @group legacy
*/
class LegacyCollectionValidatorCustomArrayObjectLegacyApiTest extends CollectionValidatorCustomArrayObjectTest
{
protected function getApiVersion()

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyCountValidatorArrayLegacyApiTest extends CountValidatorArrayTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyCountValidatorCountableLegacyApiTest extends CountValidatorCountableTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyCurrencyValidatorLegacyApiTest extends CurrencyValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyDateTimeValidatorLegacyApiTest extends DateTimeValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyDateValidatorLegacyApiTest extends DateValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyEmailValidatorLegacyApiTest extends EmailValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyEqualToValidatorLegacyApiTest extends EqualToValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyExpressionValidatorLegacyApiTest extends ExpressionValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyFalseValidatorLegacyApiTest extends FalseValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyFileValidatorObjectLegacyApiTest extends FileValidatorObjectTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyFileValidatorPathLegacyApiTest extends FileValidatorPathTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyGreaterThanOrEqualValidatorLegacyApiTest extends GreaterThanOrEqualValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyGreaterThanValidatorLegacyApiTest extends GreaterThanValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyIbanValidatorLegacyApiTest extends IbanValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyIdenticalToValidatorLegacyApiTest extends IdenticalToValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyImageValidatorLegacyApiTest extends ImageValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyIpValidatorLegacyApiTest extends IpValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyIsbnValidatorLegacyApiTest extends IsbnValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyIssnValidatorLegacyApiTest extends IssnValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyLanguageValidatorLegacyApiTest extends LanguageValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyLengthValidatorLegacyApiTest extends LengthValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyLessThanOrEqualValidatorLegacyApiTest extends LessThanOrEqualValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyLessThanValidatorLegacyApiTest extends LessThanValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyLocaleValidatorLegacyApiTest extends LocaleValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyLuhnValidatorLegacyApiTest extends LuhnValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyNotBlankValidatorLegacyApiTest extends NotBlankValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyNotEqualToValidatorLegacyApiTest extends NotEqualToValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyNotIdenticalToValidatorLegacyApiTest extends NotIdenticalToValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyNotNullValidatorLegacyApiTest extends NotNullValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyNullValidatorLegacyApiTest extends NullValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyRangeValidatorLegacyApiTest extends RangeValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyRegexValidatorLegacyApiTest extends RegexValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyTimeValidatorLegacyApiTest extends TimeValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyTrueValidatorLegacyApiTest extends TrueValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyTypeValidatorLegacyApiTest extends TypeValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyUrlValidatorLegacyApiTest extends UrlValidatorTest
{

View File

@ -16,6 +16,7 @@ use Symfony\Component\Validator\Validation;
/**
* @since 2.5.3
* @author Bernhard Schussek <bschussek@gmail.com>
* @group legacy
*/
class LegacyUuidValidatorLegacyApiTest extends UuidValidatorTest
{

View File

@ -20,6 +20,9 @@ use Symfony\Component\Validator\ExecutionContext;
use Symfony\Component\Validator\Tests\Fixtures\ConstraintA;
use Symfony\Component\Validator\ValidationVisitor;
/**
* @group legacy
*/
class LegacyExecutionContextTest extends \PHPUnit_Framework_TestCase
{
const TRANS_DOMAIN = 'trans_domain';

View File

@ -19,6 +19,9 @@ use Symfony\Component\Validator\Tests\Fixtures\Entity;
use Symfony\Component\Validator\Tests\Validator\AbstractLegacyApiTest;
use Symfony\Component\Validator\Validator as LegacyValidator;
/**
* @group legacy
*/
class LegacyValidatorTest extends AbstractLegacyApiTest
{
protected function createValidator(MetadataFactoryInterface $metadataFactory, array $objectInitializers = array())

View File

@ -13,6 +13,9 @@ namespace Symfony\Component\Validator\Tests\Mapping\Cache;
use Symfony\Component\Validator\Mapping\Cache\ApcCache;
/**
* @group legacy
*/
class LegacyApcCacheTest extends \PHPUnit_Framework_TestCase
{
protected function setUp()

View File

@ -15,6 +15,9 @@ use Symfony\Component\Validator\Mapping\ElementMetadata;
use Symfony\Component\Validator\Tests\Fixtures\ConstraintA;
use Symfony\Component\Validator\Tests\Fixtures\ConstraintB;
/**
* @group legacy
*/
class LegacyElementMetadataTest extends \PHPUnit_Framework_TestCase
{
protected $metadata;

View File

@ -35,6 +35,9 @@ class MemberMetadataTest extends \PHPUnit_Framework_TestCase
$this->metadata = null;
}
/**
* @group legacy
*/
public function testLegacyAddValidSetsMemberToCascaded()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -46,6 +49,9 @@ class MemberMetadataTest extends \PHPUnit_Framework_TestCase
$this->assertTrue($this->metadata->isCascaded());
}
/**
* @group legacy
*/
public function testLegacyAddOtherConstraintDoesNotSetMemberToCascaded()
{
$this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
@ -83,6 +89,9 @@ class MemberMetadataTest extends \PHPUnit_Framework_TestCase
$this->assertEquals($this->metadata, $metadata);
}
/**
* @group legacy
*/
public function testLegacySerializeCollectionCascadedDeeply()
{
$this->metadata->addConstraint(new Valid(array('traverse' => true)));

View File

@ -566,6 +566,7 @@ abstract class Abstract2Dot5ApiTest extends AbstractValidatorTest
/**
* @expectedException \Symfony\Component\Validator\Exception\UnsupportedMetadataException
* @group legacy
*/
public function testLegacyPropertyMetadataMustImplementPropertyMetadataInterface()
{

View File

@ -823,6 +823,7 @@ abstract class AbstractValidatorTest extends \PHPUnit_Framework_TestCase
* Cannot be UnsupportedMetadataException for BC with Symfony < 2.5.
*
* @expectedException \Symfony\Component\Validator\Exception\ValidatorException
* @group legacy
*/
public function testLegacyValidatePropertyFailsIfPropertiesNotSupported()
{
@ -952,6 +953,7 @@ abstract class AbstractValidatorTest extends \PHPUnit_Framework_TestCase
* Cannot be UnsupportedMetadataException for BC with Symfony < 2.5.
*
* @expectedException \Symfony\Component\Validator\Exception\ValidatorException
* @group legacy
*/
public function testLegacyValidatePropertyValueFailsIfPropertiesNotSupported()
{

Some files were not shown because too many files have changed in this diff Show More