From d47f5f75f7f9a44178bf6da999db2505334422c2 Mon Sep 17 00:00:00 2001 From: "Andrew (Andrius) Marcinkevicius" Date: Sat, 24 Jan 2015 08:49:04 +0200 Subject: [PATCH 1/5] Remove horizontal scrollbar | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 2.3 | Fixed tickets | --- cookbook/testing/profiling.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cookbook/testing/profiling.rst b/cookbook/testing/profiling.rst index deb242498f2..0f822cc2079 100644 --- a/cookbook/testing/profiling.rst +++ b/cookbook/testing/profiling.rst @@ -21,7 +21,8 @@ the ``test`` environment):: { $client = static::createClient(); - // Enable the profiler for the next request (it does nothing if the profiler is not available) + // Enable the profiler for the next request + // (it does nothing if the profiler is not available) $client->enableProfiler(); $crawler = $client->request('GET', '/hello/Fabien'); From 759ad10031c21a7fd6bc4ccd932d8b5e7b41d7a6 Mon Sep 17 00:00:00 2001 From: "Andrew (Andrius) Marcinkevicius" Date: Sat, 24 Jan 2015 08:55:38 +0200 Subject: [PATCH 2/5] Remove horizontal scrollbar | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 2.3 | Fixed tickets | --- cookbook/testing/database.rst | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/cookbook/testing/database.rst b/cookbook/testing/database.rst index 5a8709ac3db..cccf13136e5 100644 --- a/cookbook/testing/database.rst +++ b/cookbook/testing/database.rst @@ -48,7 +48,8 @@ Suppose the class you want to test looks like this:: public function calculateTotalSalary($id) { - $employeeRepository = $this->entityManager->getRepository('AppBundle::Employee'); + $employeeRepository = $this->entityManager + ->getRepository('AppBundle::Employee'); $employee = $employeeRepository->find($id); return $employee->getSalary() + $employee->getBonus(); @@ -74,7 +75,8 @@ it's easy to pass a mock object within a test:: ->will($this->returnValue(1100)); // Now, mock the repository so it returns the mock of the employee - $employeeRepository = $this->getMockBuilder('\Doctrine\ORM\EntityRepository') + $employeeRepository = $this + ->getMockBuilder('\Doctrine\ORM\EntityRepository') ->disableOriginalConstructor() ->getMock(); $employeeRepository->expects($this->once()) @@ -82,7 +84,8 @@ it's easy to pass a mock object within a test:: ->will($this->returnValue($employee)); // Last, mock the EntityManager to return the mock of the repository - $entityManager = $this->getMockBuilder('\Doctrine\Common\Persistence\ObjectManager') + $entityManager = $this + ->getMockBuilder('\Doctrine\Common\Persistence\ObjectManager') ->disableOriginalConstructor() ->getMock(); $entityManager->expects($this->once()) From 2e5c054e6b947a2bd7e142d90b625b2a9845381b Mon Sep 17 00:00:00 2001 From: "Andrew (Andrius) Marcinkevicius" Date: Sat, 24 Jan 2015 09:28:22 +0200 Subject: [PATCH 3/5] Remove horizontal scrollbar, fix command with version | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 2.3 | Fixed tickets | --- components/using_components.rst | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/using_components.rst b/components/using_components.rst index 4103b956afc..2f2f18380d9 100644 --- a/components/using_components.rst +++ b/components/using_components.rst @@ -40,7 +40,7 @@ If you know you need a specific version of the library, add that to the command: .. code-block:: bash - $ composer require symfony/finder + $ composer require symfony/finder:2.6.2 **3.** Write your code! @@ -51,7 +51,8 @@ immediately:: // File example: src/script.php - // update this to the path to the "vendor/" directory, relative to this file + // update this to the path to the "vendor/" + // directory, relative to this file require_once __DIR__.'/../vendor/autoload.php'; use Symfony\Component\Finder\Finder; From 9c1c071dbd17e166f8d9a47752d8ee802f111940 Mon Sep 17 00:00:00 2001 From: "Andrew (Andrius) Marcinkevicius" Date: Sun, 25 Jan 2015 10:49:47 +0200 Subject: [PATCH 4/5] Update using_components.rst --- components/using_components.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/using_components.rst b/components/using_components.rst index 2f2f18380d9..935df878064 100644 --- a/components/using_components.rst +++ b/components/using_components.rst @@ -40,7 +40,7 @@ If you know you need a specific version of the library, add that to the command: .. code-block:: bash - $ composer require symfony/finder:2.6.2 + $ composer require symfony/finder 2.6.2 **3.** Write your code! From 11422dbcb06b500ee2121e80518fca13480f5c23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrew=20Marcinkevi=C4=8Dius?= Date: Sun, 8 Mar 2015 20:34:43 +0200 Subject: [PATCH 5/5] Update using_components.rst --- components/using_components.rst | 6 ------ 1 file changed, 6 deletions(-) diff --git a/components/using_components.rst b/components/using_components.rst index 935df878064..e9c7ce56c27 100644 --- a/components/using_components.rst +++ b/components/using_components.rst @@ -36,12 +36,6 @@ whatever component you want. file in your directory. In that case, no worries! Just run ``php composer.phar require symfony/finder``. -If you know you need a specific version of the library, add that to the command: - -.. code-block:: bash - - $ composer require symfony/finder 2.6.2 - **3.** Write your code! Once Composer has downloaded the component(s), all you need to do is include