8000 [2.3] Remove useless tests skips · symfony/symfony@d649bef · GitHub
[go: up one dir, main page]

Skip to content

Commit d649bef

Browse files
[2.3] Remove useless tests skips
1 parent 1d68ad3 commit d649bef

File tree

151 files changed

+16
-1303
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

151 files changed

+16
-1303
lines changed

src/Symfony/Bridge/Doctrine/Tests/ContainerAwareEventManagerTest.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,6 @@ class ContainerAwareEventManagerTest extends \PHPUnit_Framework_TestCase
1818
{
1919
protected function setUp()
2020
{
21-
if (!class_exists('Symfony\Component\DependencyInjection\Container')) {
22-
$this->markTestSkipped('The "DependencyInjection" component is not available');
23-
}
24-
2521
$this->container = new Container();
2622
$this->evm = new ContainerAwareEventManager($this->container);
2723
}

src/Symfony/Bridge/Doctrine/Tests/DataCollector/DoctrineDataCollectorTest.php

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,17 +18,6 @@
1818

1919
class DoctrineDataCollectorTest extends \PHPUnit_Framework_TestCase
2020
{
21-
protected function setUp()
22-
{
23-
if (!class_exists('Doctrine\DBAL\Platforms\MySqlPlatform')) {
24-
$this->markTestSkipped('Doctrine DBAL is not available.');
25-
}
26-
27-
if (!class_exists('Symfony\Component\HttpKernel\HttpKernel')) {
28-
$this->markTestSkipped('The "HttpKernel" component is not available');
29-
}
30-
}
31-
3221
public function testCollectConnections()
3322
{
3423
$c = $this->createCollector(array());

src/Symfony/Bridge/Doctrine/Tests/DataFixtures/ContainerAwareLoaderTest.php

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,6 @@
1616

1717
class ContainerAwareLoaderTest extends \PHPUnit_Framework_TestCase
1818
{
19-
protected function setUp()
20-
{
21-
if (!class_exists('Symfony\Component\DependencyInjection\Container')) {
22-
$this->markTestSkipped('The "DependencyInjection" component is not available');
23-
}
24-
25-
if (!class_exists('Doctrine\Common\DataFixtures\Loader')) {
26-
$this->markTestSkipped('Doctrine Data Fixtures is not available.');
27-
}
28-
}
29-
3019
public function testShouldSetContainerOnContainerAwareFixture()
3120
{
3221
$container = $this->getMock('Symfony\Component\DependencyInjection\ContainerInterface');

src/Symfony/Bridge/Doctrine/Tests/DependencyInjection/CompilerPass/RegisterEventListenersAndSubscribersPassTest.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,6 @@
1717

1818
class RegisterEventListenersAndSubscribersPassTest extends \PHPUnit_Framework_TestCase
1919
{
20-
protected function setUp()
21-
{
22-
if (!class_exists('Symfony\Component\DependencyInjection\Container')) {
23-
$this->markTestSkipped('The "DependencyInjection" component is not available');
24-
}
25-
}
26-
2720
/**
2821
* @expectedException \InvalidArgumentException
2922
*/

src/Symfony/Bridge/Doctrine/Tests/DoctrineOrmTestCase.php

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,21 +21,6 @@
2121
*/
2222
abstract class DoctrineOrmTestCase extends \PHPUnit_Framework_TestCase
2323
{
24-
protected function setUp()
25-
{
26-
if (!class_exists('Doctrine\Common\Version')) {
27-
$this->markTestSkipped('Doctrine Common is not available.');
28-
}
29-
30-
if (!class_exists('Doctrine\DBAL\Platforms\MySqlPlatform')) {
31-
$this->markTestSkipped('Doctrine DBAL is not available.');
32-
}
33-
34-
if (!class_exists('Doctrine\ORM\EntityManager')) {
35-
$this->markTestSkipped('Doctrine ORM is not available.');
36-
}
37-
}
38-
3924
/**
4025
* @return \Doctrine\ORM\EntityManager
4126
*/

src/Symfony/Bridge/Doctrine/Tests/Form/ChoiceList/AbstractEntityChoiceListTest.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -36,22 +36,6 @@ abstract class AbstractEntityChoiceListTest extends AbstractChoiceListTest
3636

3737
protected function setUp()
3838
{
39-
if (!class_exists('Symfony\Component\Form\Form')) {
40-
$this->markTestSkipped('The "Form" component is not available');
41-
}
42-
43-
if (!class_exists('Doctrine\DBAL\Platforms\MySqlPlatform')) {
44-
$this->markTestSkipped('Doctrine DBAL is not available.');
45-
}
46-
47-
if (!class_exists('Doctrine\Common\Version')) {
48-
$this->markTestSkipped('Doctrine Common is not available.');
49-
}
50-
51-
if (!class_exists('Doctrine\ORM\EntityManager')) {
52-
$this->markTestSkipped('Doctrine ORM is not available.');
53-
}
54-
5539
$this->em = DoctrineTestHelper::createTestEntityManager();
5640

5741
$schemaTool = new SchemaTool($this->em);

src/Symfony/Bridge/Doctrine/Tests/Form/ChoiceList/GenericEntityChoiceListTest.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -36,22 +36,6 @@ class GenericEntityChoiceListTest extends \PHPUnit_Framework_TestCase
3636

3737
protected function setUp()
3838
{
39-
if (!class_exists('Symfony\Component\Form\Form')) {
40-
$this->markTestSkipped('The "Form" component is not available');
41-
}
42-
43-
if (!class_exists('Doctrine\DBAL\Platforms\MySqlPlatform')) {
44-
$this->markTestSkipped('Doctrine DBAL is not available.');
45-
}
46-
47-
if (!class_exists('Doctrine\Common\Version')) {
48-
$this->markTestSkipped('Doctrine Common is not available.');
49-
}
50-
51-
if (!class_exists('Doctrine\ORM\EntityManager')) {
52-
$this->markTestSkipped('Doctrine ORM is not available.');
53-
}
54-
5539
$this->em = DoctrineTestHelper::createTestEntityManager();
5640

5741
$schemaTool = new SchemaTool($this->em);

src/Symfony/Bridge/Doctrine/Tests/Form/Type/EntityTypePerformanceTest.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -50,22 +50,6 @@ protected function getExtensions()
5050

5151
protected function setUp()
5252
{
53-
if (!class_exists('Symfony\Component\Form\Form')) {
54-
$this->markTestSkipped('The "Form" component is not available');
55-
}
56-
57-
if (!class_exists('Doctrine\DBAL\Platforms\MySqlPlatform')) {
58-
$this->markTestSkipped('Doctrine DBAL is not available.');
59-
}
60-
61-
if (!class_exists('Doctrine\Common\Version')) {
62-
$this->markTestSkipped('Doctrine Common is not available.');
63-
}
64-
65-
if (!class_exists('Doctrine\ORM\EntityManager')) {
66-
$this->markTestSkipped('Doctrine ORM is not available.');
67-
}
68-
6953
$this->em = DoctrineTestHelper::createTestEntityManager();
7054

7155
parent::setUp();

src/Symfony/Bridge/Doctrine/Tests/Form/Type/EntityTypeTest.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -43,22 +43,6 @@ class EntityTypeTest extends TypeTestCase
4343

4444
protected function setUp()
4545
{
46-
if (!class_exists('Symfony\Component\Form\Form')) {
47-
$this->markTestSkipped('The "Form" component is not available');
48-
}
49-
50-
if (!class_exists('Doctrine\DBAL\Platforms\MySqlPlatform')) {
51-
$this->markTestSkipped('Doctrine DBAL is not available.');
52-
}
53-
54-
if (!class_exists('Doctrine\Common\Version')) {
55-
$this->markTestSkipped('Doctrine Common is not available.');
56-
}
57-
58-
if (!class_exists('Doctrine\ORM\EntityManager')) {
59-
$this->markTestSkipped('Doctrine ORM is not available.');
60-
}
61-
6246
$this->em = DoctrineTestHelper::createTestEntityManager();
6347
$this->emRegistry = $this->createRegistryMock('default', $this->em);
6448

src/Symfony/Bridge/Doctrine/Tests/HttpFoundation/DbalSessionHandlerTest.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,6 @@
2020
*/
2121
class DbalSessionHandlerTest extends \PHPUnit_Framework_TestCase
2222
{
23-
protected function setUp()
24-
{
25-
if (!class_exists('Symfony\Component\HttpFoundation\Request')) {
26-
$this->markTestSkipped('The "HttpFoundation" component is not available');
27-
}
28-
}
29-
3023
public function testConstruct()
3124
{
3225
$connection = $this->getMockBuilder('Doctrine\DBAL\Connection')->disableOriginalConstructor()->getMock();

src/Symfony/Bridge/Doctrine/Tests/Security/User/EntityUserProviderTest.php

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,6 @@
1818

1919
class EntityUserProviderTest extends \PHPUnit_Framework_TestCase
2020
{
21-
protected function setUp()
22-
{
23-
if (!class_exists('Symfony\Component\Security\Core\SecurityContext')) {
24-
$this->markTestSkipped('The "Security" component is not available');
25-
}
26-
27-
parent::setUp();
28-
}
29-
3021
public function testRefreshUserGetsUserByPrimaryKey()
3122
{
3223
$em = DoctrineTestHelper::createTestEntityManager();

src/Symfony/Bridge/Monolog/Tests/Processor/WebProcessorTest.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,6 @@
1818

1919
class WebProcessorTest extends \PHPUnit_Framework_TestCase
2020
{
21-
protected function setUp()
22-
{
23-
if (!class_exists('Monolog\\Logger')) {
24-
$this->markTestSkipped('Monolog is not available.');
25-
}
26-
}
27-
2821
public function testUsesRequestServerData()
2922
{
3023
$server = array(

src/Symfony/Bridge/Propel1/Tests/DataCollector/PropelDataCollectorTest.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,6 @@
1818

1919
class PropelDataCollectorTest extends Propel1TestCase
2020
{
21-
protected function setUp()
22-
{
23-
if (!class_exists('Symfony\Component\HttpFoundation\Request')) {
24-
$this->markTestSkipped('The "HttpFoundation" component is not available');
25-
}
26-
}
27-
2821
public function testCollectWithoutData()
2922
{
3023
$c = $this->createCollector(array());

src/Symfony/Bridge/Propel1/Tests/Form/ChoiceList/CompatModelChoiceListTest.php

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -21,23 +21,6 @@ class CompatModelChoiceListTest extends AbstractChoiceListTest
2121
protected $item3;
2222
protected $item4;
2323

24-
public static function setUpBeforeClass()
25-
{
26-
if (!class_exists('\Propel')) {
27-
self::markTestSkipped('Propel is not available.');
28-
}
29-
30-
if (!class_exists('Symfony\Component\Form\Form')) {
31-
self::markTestSkipped('The "Form" component is not available');
32-
}
33-
34-
if (!class_exists('Symfony\Component\PropertyAccess\PropertyAccessor')) {
35-
self::markTestSkipped('The "PropertyAccessor" component is not available');
36-
}
37-
38-
parent::setUpBeforeClass();
39-
}
40-
4124
public function testGetChoicesForValues()
4225
{
4326
$this->query

src/Symfony/Bridge/Propel1/Tests/Form/ChoiceList/ModelChoiceListTest.php

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,6 @@ class ModelChoiceListTest extends Propel1TestCase
2222
{
2323
const ITEM_CLASS = '\Symfony\Bridge\Propel1\Tests\Fixtures\Item';
2424

25-
public static function setUpBeforeClass()
26-
{
27-
parent::setUpBeforeClass();
28-
29-
if (!class_exists('Symfony\Component\Form\Form')) {
30-
self::markTestSkipped('The "Form" component is not available');
31-
}
32-
33-
if (!class_exists('Symfony\Component\PropertyAccess\PropertyAccessor')) {
34-
self::markTestSkipped('The "PropertyAccessor" component is not available');
35-
}
36-
}
37-
3825
protected function setUp()
3926
{
4027
ItemQuery::$result = array();

src/Symfony/Bridge/Propel1/Tests/Form/DataTransformer/CollectionToArrayTransformerTest.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,6 @@ class CollectionToArrayTransformerTest extends Propel1TestCase
2020

2121
protected function setUp()
2222
{
23-
if (!class_exists('Symfony\Component\Form\Form')) {
24-
$this->markTestSkipped('The "Form" component is not available');
25-
}
26-
27-
parent::setUp();
28-
2923
$this->transformer = new CollectionToArrayTransformer();
3024
}
3125

src/Symfony/Bridge/Propel1/Tests/Propel1TestCase.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,4 @@
1313

1414
abstract class Propel1TestCase extends \PHPUnit_Framework_TestCase
1515
{
16-
public static function setUpBeforeClass()
17-
{
18-
if (!class_exists('\Propel')) {
19-
self::markTestSkipped('Propel is not available.');
20-
}
21-
}
2216
}

src/Symfony/Bridge/Twig/Tests/Extension/HttpKernelExtensionTest.php

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,6 @@
1818

1919
class HttpKernelExtensionTest extends TestCase
2020
{
21-
protected function setUp()
22-
{
23-
parent::setUp();
24-
25-
if (!class_exists('Symfony\Component\HttpKernel\HttpKernel')) {
26-
$this->markTestSkipped('The "HttpKernel" component is not available');
27-
}
28-
29-
if (!class_exists('Twig_Environment')) {
30-
$this->markTestSkipped('Twig is not available.');
31-
}
32-
}
33-
3421
/**
3522
* @expectedException \Twig_Error_Runtime
3623
*/

src/Symfony/Bridge/Twig/Tests/Extension/RoutingExtensionTest.php

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,6 @@
1616

1717
class RoutingExtensionTest extends TestCase
1818
{
19-
protected function setUp()
20-
{
21-
parent::setUp();
22-
23-
if (!class_exists('Symfony\Component\Routing\Route')) {
24-
$this->markTestSkipped('The "Routing" component is not available');
25-
}
26-
}
27-
2819
/**
2920
* @dataProvider getEscapingTemplates
3021
*/

src/Symfony/Bridge/Twig/Tests/Extension/TranslationExtensionTest.php

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,6 @@
1919

2020
class TranslationExtensionTest extends TestCase
2121
{
22-
protected function setUp()
23-
{
24-
parent::setUp();
25-
26-
if (!class_exists('Symfony\Component\Translation\Translator')) {
27-
$this->markTestSkipped('The "Translation" component is not available');
28-
}
29-
30-
if (!class_exists('Twig_Environment')) {
31-
$this->markTestSkipped('Twig is not available.');
32-
}
33-
}
34-
3522
public function testEscaping()
3623
{
3724
$output = $this->getTemplate('{% trans %}Percent: %value%%% (%msg%){% endtrans %}')->render(array('value' => 12, 'msg' => 'approx.'));

src/Symfony/Bridge/Twig/Tests/TestCase.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,4 @@
1313

1414
abstract class TestCase extends \PHPUnit_Framework_TestCase
1515
{
16-
protected function setUp()
17-
{
18-
if (!class_exists('Twig_Environment')) {
19-
$this->markTestSkipped('Twig is not available.');
20-
}
21-
}
2216
}

src/Symfony/Bridge/Twig/Tests/Translation/TwigExtractorTest.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,6 @@
1818

1919
class TwigExtractorTest extends TestCase
2020
{
21-
protected function setUp()
22-
{
23-
if (!class_exists('Symfony\Component\Translation\Translator')) {
24-
$this->markTestSkipped('The "Translation" component is not available');
25-
}
26-
}
27-
2821
/**
2922
* @dataProvider getExtractData
3023
*/

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/FrameworkExtensionTest.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -235,10 +235,6 @@ public function testValidation()
235235

236236
public function testAnnotations()
237237
{
238-
if (!class_exists('Doctrine\\Common\\Version')) {
239-
$this->markTestSkipped('Doctrine is not available.');
240-
}
241-
242238
$container = $this->createContainerFromFile('full');
243239

244240
$this->assertEquals($container->getParameter('kernel.cache_dir').'/annotations', $container->getDefinition('annotations.file_cache_reader')->getArgument(1));

0 commit comments

Comments
 (0)
0