Conditions | 1 |
Paths | 1 |
Total Lines | 29 |
Code Lines | 20 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
25 | public function testCreate() |
||
26 | { |
||
27 | $logger = $this->createMock(LoggerInterface::class); |
||
28 | $loggerFacade = $this->createMock(LoggerFacadeInterface::class); |
||
29 | $loggerFacade |
||
30 | ->expects($this->once()) |
||
31 | ->method('getLogger') |
||
32 | ->with('test') |
||
33 | ->willReturn($logger); |
||
34 | |||
35 | $pluginCfg = $this->createMock(DTOPluginConfigurationInterface::class); |
||
36 | $pluginCfg |
||
37 | ->expects($this->once()) |
||
38 | ->method('getLoggerName') |
||
39 | ->willReturn('test'); |
||
40 | |||
41 | $fileLocatorFactory = $this->createMock(FileLocatorFactoryInterface::class); |
||
42 | |||
43 | $factory = new GeneratorFactory( |
||
44 | $fileLocatorFactory, |
||
45 | $pluginCfg, |
||
46 | $loggerFacade, |
||
47 | ); |
||
48 | |||
49 | $generator = $factory->create(); |
||
50 | |||
51 | $this->assertNotNull($generator); |
||
52 | |||
53 | $generator->generate(); |
||
54 | } |
||
56 |