diff --git a/src/Symfony/Finder/Factory.php b/src/Symfony/Finder/Factory.php new file mode 100644 index 0000000000000000000000000000000000000000..918b23d6d08169e0aef0933d29323b7ecc0bbee3 --- /dev/null +++ b/src/Symfony/Finder/Factory.php @@ -0,0 +1,40 @@ +<?php + +namespace Higidi\ComposerPhpCSStandardsPlugin\Symfony\Finder; + +/* + * Copyright (C) 2017 Daniel HĂźrtgen <daniel@higidi.de> + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA. + */ + +use Symfony\Component\Finder\Finder; + +/** + * Symfony finder factory class. + */ +class Factory +{ + /** + * Creates new symfony finder instance.. + * + * @return Finder + */ + public function create() + { + return Finder::create(); + } +} diff --git a/tests/src/Symfony/Finder/FactoryTest.php b/tests/src/Symfony/Finder/FactoryTest.php new file mode 100644 index 0000000000000000000000000000000000000000..dc4dd15b4a62e69d2ed083475cbd7b7a0ae3e1e4 --- /dev/null +++ b/tests/src/Symfony/Finder/FactoryTest.php @@ -0,0 +1,38 @@ +<?php + +namespace Higidi\ComposerPhpCSStandardsPlugin\Tests\Symfony\Finder; + +/* + * Copyright (C) 2017 Daniel HĂźrtgen <daniel@higidi.de> + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA. + */ + +use Higidi\ComposerPhpCSStandardsPlugin\Symfony\Finder\Factory; + +/** + * Test case for class \Higidi\ComposerPhpCSStandardsPlugin\Symfony\Finder\Factory + */ +class FactoryTest extends \PHPUnit_Framework_TestCase +{ + public function testCreateFinder() + { + $factory = new Factory(); + $finder = $factory->create(); + + $this->assertInstanceOf('Symfony\Component\Finder\Finder', $finder); + } +}