Deleted unused form

This commit is contained in:
Kevin Frantz 2019-02-13 18:13:30 +01:00
parent 1bc85c994e
commit 559aa60e0f
2 changed files with 0 additions and 64 deletions

View File

@ -1,23 +0,0 @@
<?php
namespace App\Form;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Component\Form\Extension\Core\Type\TextType;
use App\Entity\Source\Primitive\NameSource;
class NameSourceType extends AbstractType
{
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder->add('name', TextType::class);
}
public function configureOptions(OptionsResolver $resolver)
{
$resolver->setDefaults([
'data_class' => NameSource::class,
]);
}
}

View File

@ -1,41 +0,0 @@
<?php
namespace Tests\Unit\Form;
use PHPUnit\Framework\TestCase;
use App\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
use App\Form\NameSourceType;
/**
* This class just exists to keep the code coverage high.
*
* @todo Implement better tests!
*
* @author kevinfrantz
*/
class NameSourceTypeTest extends TestCase
{
/**
* @var AbstractType
*/
protected $type;
public function setUp(): void
{
$this->type = new NameSourceType();
}
public function testBuildForm(): void
{
$builder = $this->createMock(FormBuilderInterface::class);
$this->assertNull($this->type->buildForm($builder, []));
}
public function testConfigureOptions(): void
{
$resolver = $this->createMock(OptionsResolver::class);
$this->assertNull($this->type->configureOptions($resolver));
}
}