Completed
Push — ezp_30981_content_info_proxy ( 673505...48125a )
by
unknown
13:11
created

EzPublishCoreBundleTest::testBoot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 11

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 0
dl 0
loc 11
rs 9.9
c 0
b 0
f 0
1
<?php
2
3
/**
4
 * @copyright Copyright (C) eZ Systems AS. All rights reserved.
5
 * @license For full copyright and license information view LICENSE file distributed with this source code.
6
 */
7
declare(strict_types=1);
8
9
namespace eZ\Bundle\EzPublishCoreBundle\Tests;
10
11
use eZ\Bundle\EzPublishCoreBundle\EzPublishCoreBundle;
12
use eZ\Publish\Core\Repository\ProxyFactory\LazyLoadingValueHolderFactory;
13
use PHPUnit\Framework\TestCase;
14
use Symfony\Component\DependencyInjection\ContainerInterface;
15
16
final class EzPublishCoreBundleTest extends TestCase
17
{
18
    /** @var \eZ\Bundle\EzPublishCoreBundle\EzPublishCoreBundle */
19
    private $bundle;
20
21
    protected function setUp(): void
22
    {
23
        $this->bundle = new EzPublishCoreBundle();
24
    }
25
26
    public function testBoot(): void
27
    {
28
        $lazyLoadingValueHolderFactory = $this->createMock(LazyLoadingValueHolderFactory::class);
29
        $lazyLoadingValueHolderFactory->expects($this->once())->method('registerAutoloader');
30
31
        $container = $this->createMock(ContainerInterface::class);
32
        $container->method('get')->with(LazyLoadingValueHolderFactory::class)->willReturn($lazyLoadingValueHolderFactory);
0 ignored issues
show
Bug introduced by
The method method() does not seem to exist on object<PHPUnit\Framework\MockObject\MockObject>.

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
33
34
        $this->bundle->setContainer($container);
35
        $this->bundle->boot();
36
    }
37
}
38