|
@@ -62,7 +62,23 @@ class ChoiceTypeExtensionTest extends PHPUnit_Framework_TestCase
|
|
{
|
|
{
|
|
$extension = new ChoiceTypeExtension();
|
|
$extension = new ChoiceTypeExtension();
|
|
|
|
|
|
- $this->assertSame('choice', $extension->getExtendedType());
|
|
|
|
|
|
+ /*
|
|
|
|
+ * NEXT_MAJOR: Remove when dropping Symfony <2.8 support. It should
|
|
|
|
+ * simply be:
|
|
|
|
+ *
|
|
|
|
+ * $this->assertSame(
|
|
|
|
+ * 'Symfony\Component\Form\Extension\Core\Type\ChoiceType',
|
|
|
|
+ * $extension->getExtendedType()
|
|
|
|
+ * );
|
|
|
|
+ */
|
|
|
|
+ if (method_exists('Symfony\Component\Form\AbstractType', 'getBlockPrefix')) {
|
|
|
|
+ $this->assertSame(
|
|
|
|
+ 'Symfony\Component\Form\Extension\Core\Type\ChoiceType',
|
|
|
|
+ $extension->getExtendedType()
|
|
|
|
+ );
|
|
|
|
+ } else {
|
|
|
|
+ $this->assertSame('choice', $extension->getExtendedType());
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
public function testDefaultOptionsWithSortable()
|
|
public function testDefaultOptionsWithSortable()
|