Преглед изворни кода

Merge remote branch 'pborreli/daily-typos'

* pborreli/daily-typos:
  [Tests] Fixed Typo
  [Validator] Fixed Typo
  [Security] Fixed Typo
  [HttpKernel] Fixed Typo
  [Form] Fixed Typo
  [DependencyInjection] Fixed Typo
  [CssSelector] Fixed Typo
  [Doctrine*Bundle] Fixed Typo
  [TwigBundle] Fixed Typo
  [HttpFoundation] Removed remove recurring test
Fabien Potencier пре 14 година
родитељ
комит
d7fa78d790
29 измењених фајлова са 43 додато и 40 уклоњено
  1. 1 1
      src/Symfony/Bundle/DoctrineAbstractBundle/DependencyInjection/AbstractDoctrineExtension.php
  2. 1 1
      src/Symfony/Bundle/DoctrineBundle/Command/InfoDoctrineCommand.php
  3. 1 1
      src/Symfony/Bundle/DoctrineBundle/DependencyInjection/DoctrineExtension.php
  4. 1 1
      src/Symfony/Bundle/DoctrineBundle/Tests/DependencyInjection/AbstractDoctrineExtensionTest.php
  5. 1 1
      src/Symfony/Bundle/DoctrineBundle/Tests/DependencyInjection/XMLSchemaTest.php
  6. 1 1
      src/Symfony/Bundle/DoctrineMongoDBBundle/CacheWarmer/ProxyCacheWarmer.php
  7. 1 1
      src/Symfony/Bundle/DoctrineMongoDBBundle/Tests/CacheWarmer/HydratorCacheWarmerTest.php
  8. 1 1
      src/Symfony/Bundle/TwigBundle/Tests/TwigEngineTest.php
  9. 1 1
      src/Symfony/Component/CssSelector/Node/AttribNode.php
  10. 1 1
      src/Symfony/Component/CssSelector/Parser.php
  11. 1 1
      src/Symfony/Component/DependencyInjection/Compiler/ResolveInvalidReferencesPass.php
  12. 1 1
      src/Symfony/Component/Form/FormContext.php
  13. 1 1
      src/Symfony/Component/HttpFoundation/File/MimeType/ContentTypeMimeTypeGuesser.php
  14. 1 1
      src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php
  15. 2 1
      src/Symfony/Component/Security/Acl/Dbal/AclProvider.php
  16. 7 5
      src/Symfony/Component/Security/Http/RememberMe/TokenBasedRememberMeServices.php
  17. 1 1
      src/Symfony/Component/Validator/ValidatorContext.php
  18. 3 3
      tests/Symfony/Tests/Component/Console/Command/CommandTest.php
  19. 1 1
      tests/Symfony/Tests/Component/DependencyInjection/ContainerBuilderTest.php
  20. 1 1
      tests/Symfony/Tests/Component/DependencyInjection/Dumper/PhpDumperTest.php
  21. 6 6
      tests/Symfony/Tests/Component/DependencyInjection/ParameterBag/ParameterBagTest.php
  22. 1 1
      tests/Symfony/Tests/Component/DomCrawler/Field/ChoiceFormFieldTest.php
  23. 1 1
      tests/Symfony/Tests/Component/DomCrawler/Field/TextareaFormFieldTest.php
  24. 1 1
      tests/Symfony/Tests/Component/HttpFoundation/ParameterBagTest.php
  25. 1 1
      tests/Symfony/Tests/Component/HttpFoundation/RequestTest.php
  26. 1 1
      tests/Symfony/Tests/Component/HttpKernel/KernelTest.php
  27. 1 1
      tests/Symfony/Tests/Component/Routing/CompiledRouteTest.php
  28. 1 1
      tests/Symfony/Tests/Component/Routing/Matcher/UrlMatcherTest.php
  29. 1 1
      tests/Symfony/Tests/Component/Validator/Mapping/ClassMetadataTest.php

+ 1 - 1
src/Symfony/Bundle/DoctrineAbstractBundle/DependencyInjection/AbstractDoctrineExtension.php

@@ -187,7 +187,7 @@ abstract class AbstractDoctrineExtension extends Extension
     }
 
     /**
-     * Register all the collected mapping information with the object manager by registering the appropiate mapping drivers.
+     * Register all the collected mapping information with the object manager by registering the appropriate mapping drivers.
      *
      * @param array $objectManager
      * @param Container $container

+ 1 - 1
src/Symfony/Bundle/DoctrineBundle/Command/InfoDoctrineCommand.php

@@ -36,7 +36,7 @@ entities exist and possibly if their mapping information contains errors or not.
 
   <info>./app/console doctrine:mapping:info</info>
 
-If you are using multiple entitiy managers you can pick your choice with the <info>--em</info> option:
+If you are using multiple entity managers you can pick your choice with the <info>--em</info> option:
 
   <info>./app/console doctrine:mapping:info --em=default</info>
 EOT

+ 1 - 1
src/Symfony/Bundle/DoctrineBundle/DependencyInjection/DoctrineExtension.php

@@ -393,7 +393,7 @@ class DoctrineExtension extends AbstractDoctrineExtension
      * There are two possible runtime scenarios:
      *
      * 1. If the EntityManager was defined before, override only the new calls to Doctrine\ORM\Configuration
-     * 2. If the EntityManager was not defined beforeefore, gather all the defaults for not specified options and set all the information.
+     * 2. If the EntityManager was not defined before, gather all the defaults for not specified options and set all the information.
      *
      * @param array $entityManager A configured ORM entity manager.
      * @param ContainerBuilder $container A ContainerBuilder instance

+ 1 - 1
src/Symfony/Bundle/DoctrineBundle/Tests/DependencyInjection/AbstractDoctrineExtensionTest.php

@@ -683,7 +683,7 @@ abstract class AbstractDoctrineExtensionTest extends TestCase
 
     protected function assertDICConstructorArguments($definition, $args)
     {
-        $this->assertEquals($args, $definition->getArguments(), "Expected and actual DIC Service constructor arguments of definition '" . $definition->getClass()."' dont match.");
+        $this->assertEquals($args, $definition->getArguments(), "Expected and actual DIC Service constructor arguments of definition '" . $definition->getClass()."' don't match.");
     }
 
     protected function assertDICDefinitionMethodCallAt($pos, $definition, $methodName, array $params = null)

+ 1 - 1
src/Symfony/Bundle/DoctrineBundle/Tests/DependencyInjection/XMLSchemaTest.php

@@ -49,6 +49,6 @@ class XMLSchemaTest extends \PHPUnit_Framework_TestCase
             $found = true;
         }
 
-        $this->assertTrue($found, "Neither <doctrine:orm> nor <doctrine:dbal> elements found in given XML. Are namespace sconfigured correctly?");
+        $this->assertTrue($found, "Neither <doctrine:orm> nor <doctrine:dbal> elements found in given XML. Are namespaces configured correctly?");
     }
 }

+ 1 - 1
src/Symfony/Bundle/DoctrineMongoDBBundle/CacheWarmer/ProxyCacheWarmer.php

@@ -60,7 +60,7 @@ class ProxyCacheWarmer implements CacheWarmerInterface
             throw new \RuntimeException(sprintf('Doctrine Proxy directory (%s) is not writeable for the current system user.', $proxyCacheDir));
         }
 
-        // if proxys are autogenerated we don't need to generate them in the cache warmer.
+        // if proxies are autogenerated we don't need to generate them in the cache warmer.
         if ($this->container->getParameter('doctrine.odm.mongodb.auto_generate_proxy_classes') === true) {
             return;
         }

+ 1 - 1
src/Symfony/Bundle/DoctrineMongoDBBundle/Tests/CacheWarmer/HydratorCacheWarmerTest.php

@@ -16,7 +16,7 @@ use Symfony\Bundle\DoctrineMongoDBBundle\CacheWarmer\HydratorCacheWarmer;
 class HydratorCacheWarmerTest extends \Symfony\Bundle\DoctrineMongoDBBundle\Tests\TestCase
 {
     /**
-     * This is not necessarily a good test, it doesnt generate any hydrators
+     * This is not necessarily a good test, it doesn't generate any hydrators
      * because there are none in the AnnotationsBundle. However that is
      * rather a task of doctrine to test. We touch the lines here and
      * verify that the container is called correctly for the relevant information.

+ 1 - 1
src/Symfony/Bundle/TwigBundle/Tests/TwigEngineTest.php

@@ -21,7 +21,7 @@ use Symfony\Bundle\TwigBundle\GlobalVariables;
 
 class TwigEngineTest extends TestCase
 {
-    public function testEvalutateAddsAppGlobal()
+    public function testEvaluateAddsAppGlobal()
     {
         $environment = $this->getTwigEnvironment();
         $container = $this->getContainer();

+ 1 - 1
src/Symfony/Component/CssSelector/Node/AttribNode.php

@@ -118,7 +118,7 @@ class AttribNode implements NodeInterface
     /**
      * Returns a formatted attribute
      *
-     * @return string The formatted attributep
+     * @return string The formatted attribute
      */
     protected function formatAttrib()
     {

+ 1 - 1
src/Symfony/Component/CssSelector/Parser.php

@@ -273,7 +273,7 @@ class Parser
      *
      * @param  Node\NodeInterface $selector The selector object whose attribute
      *                                      is to be parsed.
-     * @param  TokenStream        $strem    The container token stream.
+     * @param  TokenStream        $stream    The container token stream.
      *
      * @return Node\AttribNode
      */

+ 1 - 1
src/Symfony/Component/DependencyInjection/Compiler/ResolveInvalidReferencesPass.php

@@ -76,7 +76,7 @@ class ResolveInvalidReferencesPass implements CompilerPassInterface
     }
 
     /**
-     * Processes arguments to determin invalid references.
+     * Processes arguments to determine invalid references.
      *
      * @param array $arguments An array of Reference objects
      * @param boolean $inMethodCall 

+ 1 - 1
src/Symfony/Component/Form/FormContext.php

@@ -16,7 +16,7 @@ use Symfony\Component\Form\Exception\FormException;
 use Symfony\Component\Validator\ValidatorInterface;
 
 /**
- * Default implementaton of FormContextInterface
+ * Default implementation of FormContextInterface
  *
  * This class is immutable by design.
  *

+ 1 - 1
src/Symfony/Component/HttpFoundation/File/MimeType/ContentTypeMimeTypeGuesser.php

@@ -46,7 +46,7 @@ class ContentTypeMimeTypeGuesser implements MimeTypeGuesserInterface
             throw new AccessDeniedException($path);
         }
 
-        if (!self::isSupported() || !is_readable($path)) {
+        if (!self::isSupported()) {
             return null;
         }
 

+ 1 - 1
src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php

@@ -340,7 +340,7 @@ class HttpCache implements HttpKernelInterface
     /**
      * Forwards the Request to the backend and determines whether the response should be stored.
      *
-     * This methods is trigered when the cache missed or a reload is required.
+     * This methods is triggered when the cache missed or a reload is required.
      *
      * @param Request  $request A Request instance
      * @param Boolean  $catch   whether to process exceptions

+ 2 - 1
src/Symfony/Component/Security/Acl/Dbal/AclProvider.php

@@ -251,7 +251,8 @@ class AclProvider implements AclProviderInterface
      * @param array $batch
      * @param array $sids
      * @param array $oidLookup
-     * @return \SplObjectStorage mapping object identites to ACL instances
+     *
+     * @return \SplObjectStorage mapping object identities to ACL instances
      */
     protected function lookupObjectIdentities(array $batch, array $sids, array $oidLookup)
     {

+ 7 - 5
src/Symfony/Component/Security/Http/RememberMe/TokenBasedRememberMeServices.php

@@ -117,13 +117,15 @@ class TokenBasedRememberMeServices extends RememberMeServices
     }
 
     /**
-     * Generates the cookie value
+     * Generates the cookie value.
+     *
+     * @param string  $class
+     * @param string  $username The username
+     * @param integer $expires  The unixtime when the cookie expires
+     * @param string  $password The encoded password
      *
-     * @param strign $class
-     * @param string $username The username
-     * @param integer $expires The unixtime when the cookie expires
-     * @param string $password The encoded password
      * @throws \RuntimeException if username contains invalid chars
+     *
      * @return string
      */
     protected function generateCookieValue($class, $username, $expires, $password)

+ 1 - 1
src/Symfony/Component/Validator/ValidatorContext.php

@@ -14,7 +14,7 @@ namespace Symfony\Component\Validator;
 use Symfony\Component\Validator\Mapping\ClassMetadataFactoryInterface;
 
 /**
- * Default implementaton of ValidatorContextInterface
+ * Default implementation of ValidatorContextInterface
  *
  * @author Bernhard Schussek <bernhard.schussek@symfony-project.com>
  */

+ 3 - 3
tests/Symfony/Tests/Component/Console/Command/CommandTest.php

@@ -210,10 +210,10 @@ class CommandTest extends \PHPUnit_Framework_TestCase
         $command = new Command('foo');
         try {
             $command->run(new StringInput(''), new NullOutput());
-            $this->fail('->run() throws a \LogicException if the execute() method has not been overriden and no code has been provided');
+            $this->fail('->run() throws a \LogicException if the execute() method has not been overridden and no code has been provided');
         } catch (\Exception $e) {
-            $this->assertInstanceOf('\LogicException', $e, '->run() throws a \LogicException if the execute() method has not been overriden and no code has been provided');
-            $this->assertEquals('You must override the execute() method in the concrete command class.', $e->getMessage(), '->run() throws a \LogicException if the execute() method has not been overriden and no code has been provided');
+            $this->assertInstanceOf('\LogicException', $e, '->run() throws a \LogicException if the execute() method has not been overridden and no code has been provided');
+            $this->assertEquals('You must override the execute() method in the concrete command class.', $e->getMessage(), '->run() throws a \LogicException if the execute() method has not been overridden and no code has been provided');
         }
     }
 

+ 1 - 1
tests/Symfony/Tests/Component/DependencyInjection/ContainerBuilderTest.php

@@ -45,7 +45,7 @@ class ContainerBuilderTest extends \PHPUnit_Framework_TestCase
 
         $builder->setDefinition('foobar', $foo = new Definition('FooBarClass'));
         $this->assertEquals($foo, $builder->getDefinition('foobar'), '->getDefinition() returns a service definition if defined');
-        $this->assertTrue($builder->setDefinition('foobar', $foo = new Definition('FooBarClass')) === $foo, '->setDefinition() implements a fuild interface by returning the service reference');
+        $this->assertTrue($builder->setDefinition('foobar', $foo = new Definition('FooBarClass')) === $foo, '->setDefinition() implements a fluid interface by returning the service reference');
 
         $builder->addDefinitions($defs = array('foobar' => new Definition('FooBarClass')));
         $this->assertEquals(array_merge($definitions, $defs), $builder->getDefinitions(), '->addDefinitions() adds the service definitions');

+ 1 - 1
tests/Symfony/Tests/Component/DependencyInjection/Dumper/PhpDumperTest.php

@@ -66,7 +66,7 @@ class PhpDumperTest extends \PHPUnit_Framework_TestCase
             $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources');
         } catch (\Exception $e) {
             $this->assertInstanceOf('\RuntimeException', $e, '->dump() returns a LogicException if the dump() method has not been overriden by a children class');
-            $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() returns a LogicException if the dump() method has not been overriden by a children class');
+            $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() returns a LogicException if the dump() method has not been overridden by a children class');
         }
     }
 

+ 6 - 6
tests/Symfony/Tests/Component/DependencyInjection/ParameterBag/ParameterBagTest.php

@@ -98,18 +98,18 @@ class ParameterBagTest extends \PHPUnit_Framework_TestCase
         $bag = new ParameterBag(array());
         try {
             $bag->resolveValue('%foobar%', array());
-            $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existant parameter');
+            $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter');
         } catch (\Exception $e) {
-            $this->assertInstanceOf('\InvalidArgumentException', $e, '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existant parameter');
-            $this->assertEquals('The parameter "foobar" must be defined.', $e->getMessage(), '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existant parameter');
+            $this->assertInstanceOf('\InvalidArgumentException', $e, '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter');
+            $this->assertEquals('The parameter "foobar" must be defined.', $e->getMessage(), '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter');
         }
 
         try {
             $bag->resolveValue('foo %foobar% bar', array());
-            $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existant parameter');
+            $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter');
         } catch (\Exception $e) {
-            $this->assertInstanceOf('\InvalidArgumentException', $e, '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existant parameter');
-            $this->assertEquals('The parameter "foobar" must be defined.', $e->getMessage(), '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existant parameter');
+            $this->assertInstanceOf('\InvalidArgumentException', $e, '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter');
+            $this->assertEquals('The parameter "foobar" must be defined.', $e->getMessage(), '->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter');
         }
     }
 }

+ 1 - 1
tests/Symfony/Tests/Component/DomCrawler/Field/ChoiceFormFieldTest.php

@@ -226,7 +226,7 @@ class ChoiceFormFieldTest extends FormFieldTestCase
         $node = $this->createNode('input', '', array('type' => 'checkbox', 'name' => 'name'));
         $field = new ChoiceFormField($node);
         $field->tick();
-        $this->assertEquals(1, $field->getValue(), '->tick() ticks checkoxes');
+        $this->assertEquals(1, $field->getValue(), '->tick() ticks checkboxes');
     }
 
     public function testUntick()

+ 1 - 1
tests/Symfony/Tests/Component/DomCrawler/Field/TextareaFormFieldTest.php

@@ -22,7 +22,7 @@ class TextareaFormFieldTest extends FormFieldTestCase
         $node = $this->createNode('textarea', 'foo bar');
         $field = new TextareaFormField($node);
 
-        $this->assertEquals('foo bar', $field->getValue(), '->initialize() sets the value of the field to the textare node value');
+        $this->assertEquals('foo bar', $field->getValue(), '->initialize() sets the value of the field to the textarea node value');
 
         $node = $this->createNode('input', '');
         try {

+ 1 - 1
tests/Symfony/Tests/Component/HttpFoundation/ParameterBagTest.php

@@ -53,7 +53,7 @@ class ParameterBagTest extends \PHPUnit_Framework_TestCase
 
         $this->assertEquals('bar', $bag->get('foo'), '->get() gets the value of a parameter');
         $this->assertEquals('default', $bag->get('unknown', 'default'), '->get() returns second argument as default if a parameter is not defined');
-        $this->assertNull($bag->get('null', 'default'), '->get() retuns null if null is set');
+        $this->assertNull($bag->get('null', 'default'), '->get() returns null if null is set');
     }
 
     /**

+ 1 - 1
tests/Symfony/Tests/Component/HttpFoundation/RequestTest.php

@@ -140,7 +140,7 @@ class RequestTest extends \PHPUnit_Framework_TestCase
     public function getFormatToMimeTypeMapProvider()
     {
         return array(
-            array(null, array(null, 'unexistant-mime-type')),
+            array(null, array(null, 'unexistent-mime-type')),
             array('txt', array('text/plain')),
             array('js', array('application/javascript', 'application/x-javascript', 'text/javascript')),
             array('css', array('text/css')),

+ 1 - 1
tests/Symfony/Tests/Component/HttpKernel/KernelTest.php

@@ -357,7 +357,7 @@ EOF;
         $kernel->initializeBundles();
     }
 
-    public function testInitializeBundlesSupportsArbitaryBundleRegistrationOrder()
+    public function testInitializeBundlesSupportsArbitraryBundleRegistrationOrder()
     {
         $grandparent = $this->getBundle(null, null, 'GrandParentCCundle');
         $parent = $this->getBundle(null, 'GrandParentCCundle', 'ParentCCundle');

+ 1 - 1
tests/Symfony/Tests/Component/Routing/CompiledRouteTest.php

@@ -25,7 +25,7 @@ class CompiledRouteTest extends \PHPUnit_Framework_TestCase
         $this->assertEquals('prefix', $compiled->getStaticPrefix(), '__construct() takes a static prefix as its second argument');
         $this->assertEquals('regex', $compiled->getRegex(), '__construct() takes a regexp as its third argument');
         $this->assertEquals(array('tokens'), $compiled->getTokens(), '__construct() takes an array of tokens as its fourth argument');
-        $this->assertEquals(array('variables'), $compiled->getVariables(), '__construct() takes an array of variables as its fith argument');
+        $this->assertEquals(array('variables'), $compiled->getVariables(), '__construct() takes an array of variables as its fifth argument');
     }
 
     public function testgetPatterngetDefaultsgetOptionsgetRequirements()

+ 1 - 1
tests/Symfony/Tests/Component/Routing/Matcher/UrlMatcherTest.php

@@ -43,7 +43,7 @@ class UrlMatcherTest extends \PHPUnit_Framework_TestCase
       $matcher = new UrlMatcher($collection, array(), array());
       $this->assertEquals(array('_route' => 'foo', 'bar' => 'baz', 'def' => 'test'), $matcher->match('/foo/baz'));
 
-      // test that route "metod" is ignore if no method is given in the context
+      // test that route "method" is ignore if no method is given in the context
       $collection = new RouteCollection();
       $collection->add('foo', new Route('/foo', array(), array('_method' => 'GET|head')));
 

+ 1 - 1
tests/Symfony/Tests/Component/Validator/Mapping/ClassMetadataTest.php

@@ -117,7 +117,7 @@ class ClassMetadataTest extends \PHPUnit_Framework_TestCase
         $this->assertFalse($this->metadata->hasMemberMetadatas('non_existant_field'));
     }
 
-    public function testMergeConstraintsKeepsPrivateMembersSeperate()
+    public function testMergeConstraintsKeepsPrivateMembersSeparate()
     {
         $parent = new ClassMetadata(self::PARENTCLASS);
         $parent->addPropertyConstraint('internal', new ConstraintA());