This commit is contained in:
Fabien Potencier 2012-04-18 10:41:11 +02:00
parent 8dc25abe1b
commit 580c8fa875
4 changed files with 13 additions and 7 deletions

View File

@ -66,7 +66,7 @@ class TwigExtensionTest extends TestCase
// Yaml and Php specific configs
if (in_array($format, array('yml', 'php'))) {
$this->assertEquals('bad', $calls[2][1][0], '->load() registers variables as Twig globals');
$this->assertEquals('bad', $calls[2][1][0], '->load() registers variables as Twig globals');
$this->assertEquals(array('key' => 'foo'), $calls[2][1][1], '->load() registers variables as Twig globals');
}

View File

@ -19,7 +19,8 @@ use Symfony\Component\Locale\Stub\StubIntl;
* @return Boolean Whether the error code indicates an error
* @see Symfony\Component\Locale\Stub\StubIntl::isFailure
*/
function intl_is_failure($errorCode) {
function intl_is_failure($errorCode)
{
return StubIntl::isFailure($errorCode);
}
@ -31,9 +32,11 @@ function intl_is_failure($errorCode) {
* StubIntl::U_ZERO_ERROR if no error occurred
* @see Symfony\Component\Locale\Stub\StubIntl::getErrorCode
*/
function intl_get_error_code() {
function intl_get_error_code()
{
return StubIntl::getErrorCode();
}
/**
* Stub implementation for the intl_get_error_code function of the intl extension
*
@ -42,7 +45,8 @@ function intl_get_error_code() {
* "U_ZERO_ERROR" if no error occurred
* @see Symfony\Component\Locale\Stub\StubIntl::getErrorMessage
*/
function intl_get_error_message() {
function intl_get_error_message()
{
return StubIntl::getErrorMessage();
}
@ -53,6 +57,7 @@ function intl_get_error_message() {
*
* @see Symfony\Component\Locale\Stub\StubIntl::getErrorName
*/
function intl_error_name($errorCode) {
function intl_error_name($errorCode)
{
return StubIntl::getErrorName($errorCode);
}
}

View File

@ -120,6 +120,7 @@ class RouteCompiler implements RouteCompilerInterface
$regexp .= str_repeat(")?", $nbTokens - $firstOptional);
}
}
return $regexp;
}
}

View File

@ -116,4 +116,4 @@ class ApacheMatcherDumperTest extends \PHPUnit_Framework_TestCase
return $collection;
}
}
}