Skip to content

Commit

Permalink
minor #33336 [HttpKernel] do not mock removed getPublicDir() method (…
Browse files Browse the repository at this point in the history
…xabbuh)

This PR was merged into the 4.4 branch.

Discussion
----------

[HttpKernel] do not mock removed getPublicDir() method

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

54cb471 do not mock removed getPublicDir() method
  • Loading branch information
yceruto committed Aug 26, 2019
2 parents d887a0d + 54cb471 commit db9549d
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions src/Symfony/Component/HttpKernel/Tests/KernelTest.php
Expand Up @@ -21,7 +21,6 @@
use Symfony\Component\HttpKernel\Bundle\BundleInterface;
use Symfony\Component\HttpKernel\DependencyInjection\ResettableServicePass;
use Symfony\Component\HttpKernel\DependencyInjection\ServicesResetter;
use Symfony\Component\HttpKernel\HttpKernel;
use Symfony\Component\HttpKernel\HttpKernelInterface;
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\HttpKernel\Tests\Fixtures\KernelForOverrideName;
Expand Down Expand Up @@ -626,7 +625,7 @@ protected function getBundle($dir = null, $parent = null, $className = null, $bu
{
$bundle = $this
->getMockBuilder('Symfony\Component\HttpKernel\Bundle\BundleInterface')
->setMethods(['getPath', 'getPublicDir', 'getParent', 'getName'])
->setMethods(['getPath', 'getName'])
->disableOriginalConstructor()
;

Expand All @@ -648,18 +647,6 @@ protected function getBundle($dir = null, $parent = null, $className = null, $bu
->willReturn($dir)
;

$bundle
->expects($this->any())
->method('getPublicDir')
->willReturn('Resources/public')
;

$bundle
->expects($this->any())
->method('getParent')
->willReturn($parent)
;

return $bundle;
}

Expand Down

0 comments on commit db9549d

Please sign in to comment.