From c83bdefcb6053a7d0c078ff358cc9944b87010a8 Mon Sep 17 00:00:00 2001 From: Mark Story Date: Sat, 24 Jul 2010 12:23:33 -0400 Subject: [PATCH] Fixing failing test in Twig_Tests_Node_Expression_FilterTest when mb extension is not installed. Fixes #93 --- test/Twig/Tests/Node/Expression/FilterTest.php | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/test/Twig/Tests/Node/Expression/FilterTest.php b/test/Twig/Tests/Node/Expression/FilterTest.php index 24b21bb..0cdd199 100644 --- a/test/Twig/Tests/Node/Expression/FilterTest.php +++ b/test/Twig/Tests/Node/Expression/FilterTest.php @@ -163,7 +163,11 @@ class Twig_Tests_Node_Expression_FilterTest extends Twig_Tests_Node_TestCase ), array(), 0); $node = new Twig_Node_Expression_Filter($expr, $filters, 0); - $tests[] = array($node, 'twig_lower_filter($this->env, twig_upper_filter($this->env, "foo"), "bar", "foobar")'); + if (function_exists('mb_get_info')) { + $tests[] = array($node, 'twig_lower_filter($this->env, twig_upper_filter($this->env, "foo"), "bar", "foobar")'); + } else { + $tests[] = array($node, 'strtolower(strtoupper("foo"), "bar", "foobar")'); + } return $tests; } -- 1.7.2.5