[2.3] More cs fixes

This commit is contained in:
Graham Campbell 2014-12-03 21:28:36 +00:00 committed by Fabien Potencier
parent cef9972484
commit b034b08506
8 changed files with 26 additions and 27 deletions

View File

@ -361,7 +361,7 @@ class FormValidatorTest extends AbstractConstraintValidatorTest
$object = $this->getMock('\stdClass');
$options = array('validation_groups' => function (FormInterface $form) {
return array('group1', 'group2');
},);
});
$form = $this->getBuilder('name', '\stdClass', $options)
->setData($object)
->getForm();

View File

@ -52,7 +52,7 @@ class CurrencyBundle extends CurrencyDataProvider implements CurrencyBundleInter
try {
return $this->getSymbol($currency, $displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -64,7 +64,7 @@ class CurrencyBundle extends CurrencyDataProvider implements CurrencyBundleInter
try {
return $this->getName($currency, $displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -76,7 +76,7 @@ class CurrencyBundle extends CurrencyDataProvider implements CurrencyBundleInter
try {
return $this->getNames($displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -88,7 +88,7 @@ class CurrencyBundle extends CurrencyDataProvider implements CurrencyBundleInter
try {
return parent::getFractionDigits($currency);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -100,7 +100,7 @@ class CurrencyBundle extends CurrencyDataProvider implements CurrencyBundleInter
try {
return parent::getRoundingIncrement($currency);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -112,7 +112,7 @@ class CurrencyBundle extends CurrencyDataProvider implements CurrencyBundleInter
try {
return $this->localeProvider->getLocales();
} catch (MissingResourceException $e) {
return null;
return;
}
}
}

View File

@ -68,7 +68,7 @@ class LanguageBundle extends LanguageDataProvider implements LanguageBundleInter
try {
return $this->getName($language, $displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -80,7 +80,7 @@ class LanguageBundle extends LanguageDataProvider implements LanguageBundleInter
try {
return $this->getNames($displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -92,7 +92,7 @@ class LanguageBundle extends LanguageDataProvider implements LanguageBundleInter
try {
return $this->scriptProvider->getName($script, $displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -104,7 +104,7 @@ class LanguageBundle extends LanguageDataProvider implements LanguageBundleInter
try {
return $this->scriptProvider->getNames($displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -116,7 +116,7 @@ class LanguageBundle extends LanguageDataProvider implements LanguageBundleInter
try {
return $this->localeProvider->getLocales();
} catch (MissingResourceException $e) {
return null;
return;
}
}
}

View File

@ -31,7 +31,7 @@ class LocaleBundle extends LocaleDataProvider implements LocaleBundleInterface
try {
return parent::getLocales();
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -43,7 +43,7 @@ class LocaleBundle extends LocaleDataProvider implements LocaleBundleInterface
try {
return $this->getName($locale, $displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -55,7 +55,7 @@ class LocaleBundle extends LocaleDataProvider implements LocaleBundleInterface
try {
return $this->getNames($displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
}

View File

@ -52,7 +52,7 @@ class RegionBundle extends RegionDataProvider implements RegionBundleInterface
try {
return $this->getName($country, $displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -64,7 +64,7 @@ class RegionBundle extends RegionDataProvider implements RegionBundleInterface
try {
return $this->getNames($displayLocale);
} catch (MissingResourceException $e) {
return null;
return;
}
}
@ -76,7 +76,7 @@ class RegionBundle extends RegionDataProvider implements RegionBundleInterface
try {
return $this->localeProvider->getLocales();
} catch (MissingResourceException $e) {
return null;
return;
}
}
}

View File

@ -76,7 +76,6 @@ foreach ($urls as $urlVersion => $url) {
? $urlVersion
: $maxVersion;
echo " $urlVersion\n";
}

View File

@ -56,13 +56,13 @@ class StopwatchTest extends \PHPUnit_Framework_TestCase
$events = new \ReflectionProperty('Symfony\Component\Stopwatch\Section', 'events');
$events->setAccessible(true);
$events->setValue(
end($section),
array(
'foo' => $this->getMockBuilder('Symfony\Component\Stopwatch\StopwatchEvent')
->setConstructorArgs(array(microtime(true) * 1000))
->getMock())
);
$stopwatchMockEvent = $this->getMockBuilder('Symfony\Component\Stopwatch\StopwatchEvent')
->setConstructorArgs(array(microtime(true) * 1000))
->getMock()
;
$events->setValue(end($section), array('foo' => $stopwatchMockEvent));
$this->assertFalse($stopwatch->isStarted('foo'));
}

View File

@ -89,7 +89,7 @@ class ChoiceValidatorTest extends AbstractConstraintValidatorTest
{
$constraint = new Choice(array('callback' => function () {
return array('foo', 'bar');
}, ));
}));
$this->validator->validate('bar', $constraint);