/**
  * @return array
  */
 protected function getExtensions()
 {
     $localeCollection = new LocaleCollectionType($this->registry);
     $localeCollection->setLocaleClass(self::LOCALE_CLASS);
     /** @var \PHPUnit_Framework_MockObject_MockObject|TranslatorInterface $translator */
     $translator = $this->getMock('Symfony\\Component\\Translation\\TranslatorInterface');
     return [new PreloadedExtension([FallbackPropertyType::NAME => new FallbackPropertyType($translator), FallbackValueType::NAME => new FallbackValueType(), LocaleCollectionType::NAME => $localeCollection, PercentTypeStub::NAME => new PercentTypeStub()], [])];
 }
예제 #2
0
 /**
  * @return array
  */
 protected function getExtensions()
 {
     $localeCollection = new LocaleCollectionType($this->registry);
     $localeCollection->setLocaleClass(self::LOCALE_CLASS);
     return [new PreloadedExtension(['text' => new TextType(), 'integer' => new IntegerType(), FallbackValueType::NAME => new FallbackValueType(), LocaleCollectionType::NAME => $localeCollection, FallbackPropertyType::NAME => new FallbackPropertyType(), HiddenFallbackValueType::NAME => new HiddenFallbackValueType()], [])];
 }
 /**
  * @return array
  */
 protected function getExtensions()
 {
     $localeCollection = new LocaleCollectionType($this->registry);
     $localeCollection->setLocaleClass(self::LOCALE_CLASS);
     return [new PreloadedExtension([FallbackPropertyType::NAME => new FallbackPropertyType(), FallbackValueType::NAME => new FallbackValueType(), LocaleCollectionType::NAME => $localeCollection, PercentTypeStub::NAME => new PercentTypeStub()], [])];
 }