Fixed typos

This commit is contained in:
Pascal Borreli
2013-03-10 02:06:44 +00:00
parent b6c2171579
commit 49488b8f24
7 changed files with 10 additions and 10 deletions
+1 -1
View File
@@ -386,7 +386,7 @@ Changes:
* enhanced error messages when an unexpected token is parsed in an expression * enhanced error messages when an unexpected token is parsed in an expression
* fixed filename not being added to syntax error messages * fixed filename not being added to syntax error messages
* added the autoescape option to enable/disable autoescaping * added the autoescape option to enable/disable autoescaping
* removed the newline after a comment (mimicks PHP behavior) * removed the newline after a comment (mimics PHP behavior)
* added a syntax error exception when parent block is used on a template that does not extend another one * added a syntax error exception when parent block is used on a template that does not extend another one
* made the Escaper extension enabled by default * made the Escaper extension enabled by default
* fixed sandbox extension when used with auto output escaping * fixed sandbox extension when used with auto output escaping
+1 -1
View File
@@ -10,7 +10,7 @@
*/ */
/** /**
* Evaluates an expression, disgarding the returned value. * Evaluates an expression, discarding the returned value.
*/ */
class Twig_TokenParser_Do extends Twig_TokenParser class Twig_TokenParser_Do extends Twig_TokenParser
{ {
+1 -1
View File
@@ -49,7 +49,7 @@ class Twig_TokenParser_Set extends Twig_TokenParser
$stream->expect(Twig_Token::BLOCK_END_TYPE); $stream->expect(Twig_Token::BLOCK_END_TYPE);
if (count($names) !== count($values)) { if (count($names) !== count($values)) {
throw new Twig_Error_Syntax("When using set, you must have the same number of variables and assignements.", $stream->getCurrent()->getLine(), $stream->getFilename()); throw new Twig_Error_Syntax("When using set, you must have the same number of variables and assignments.", $stream->getCurrent()->getLine(), $stream->getFilename());
} }
} else { } else {
$capture = true; $capture = true;
@@ -9,7 +9,7 @@
2. Conditional expression with only literals 2. Conditional expression with only literals
{{ true ? "<br />" : "<br>" }} {{ true ? "<br />" : "<br>" }}
3. Conditonal expression with a variable 3. Conditional expression with a variable
{{ true ? "<br />" : someVar }} {{ true ? "<br />" : someVar }}
4. Nested conditionals with only literals 4. Nested conditionals with only literals
@@ -32,7 +32,7 @@ return array()
2. Conditional expression with only literals 2. Conditional expression with only literals
<br /> <br />
3. Conditonal expression with a variable 3. Conditional expression with a variable
&lt;br /&gt; &lt;br /&gt;
4. Nested conditionals with only literals 4. Nested conditionals with only literals
+1 -1
View File
@@ -23,7 +23,7 @@ class Twig_Tests_ParserTest extends PHPUnit_Framework_TestCase
* @expectedException Twig_Error_Syntax * @expectedException Twig_Error_Syntax
* @expectedExceptionMessage Unknown tag name "foo". Did you mean "for" at line 1 * @expectedExceptionMessage Unknown tag name "foo". Did you mean "for" at line 1
*/ */
public function testUnkownTag() public function testUnknownTag()
{ {
$stream = new Twig_TokenStream(array( $stream = new Twig_TokenStream(array(
new Twig_Token(Twig_Token::BLOCK_START_TYPE, '', 1), new Twig_Token(Twig_Token::BLOCK_START_TYPE, '', 1),
+1 -1
View File
@@ -67,7 +67,7 @@ class Twig_Tests_TemplateTest extends PHPUnit_Framework_TestCase
public function testGetAttributeWithSandbox($object, $item, $allowed, $useExt) public function testGetAttributeWithSandbox($object, $item, $allowed, $useExt)
{ {
$twig = new Twig_Environment(); $twig = new Twig_Environment();
$policy = new Twig_Sandbox_SecurityPolicy(array(), array(), array(/*methid*/), array(/*peop*/), array()); $policy = new Twig_Sandbox_SecurityPolicy(array(), array(), array(/*method*/), array(/*prop*/), array());
$twig->addExtension(new Twig_Extension_Sandbox($policy, !$allowed)); $twig->addExtension(new Twig_Extension_Sandbox($policy, !$allowed));
$template = new Twig_TemplateTest($twig, $useExt); $template = new Twig_TemplateTest($twig, $useExt);
+3 -3
View File
@@ -29,7 +29,7 @@ class Twig_Test_EscapingTest extends PHPUnit_Framework_TestCase
'.' => '.', '.' => '.',
'-' => '-', '-' => '-',
'_' => '_', '_' => '_',
/* Basic alnums exluded */ /* Basic alnums excluded */
'a' => 'a', 'a' => 'a',
'A' => 'A', 'A' => 'A',
'z' => 'z', 'z' => 'z',
@@ -63,7 +63,7 @@ class Twig_Test_EscapingTest extends PHPUnit_Framework_TestCase
',' => ',', ',' => ',',
'.' => '.', '.' => '.',
'_' => '_', '_' => '_',
/* Basic alnums exluded */ /* Basic alnums excluded */
'a' => 'a', 'a' => 'a',
'A' => 'A', 'A' => 'A',
'z' => 'z', 'z' => 'z',
@@ -127,7 +127,7 @@ class Twig_Test_EscapingTest extends PHPUnit_Framework_TestCase
',' => '\\2C ', ',' => '\\2C ',
'.' => '\\2E ', '.' => '\\2E ',
'_' => '\\5F ', '_' => '\\5F ',
/* Basic alnums exluded */ /* Basic alnums excluded */
'a' => 'a', 'a' => 'a',
'A' => 'A', 'A' => 'A',
'z' => 'z', 'z' => 'z',