Conditions | 1 |
Paths | 1 |
Total Lines | 19 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
24 | public function testDispatchEvent() |
||
25 | { |
||
26 | $domainEvent = $this->getMock(DomainEvent::class); |
||
27 | |||
28 | $symfonyDispatcher = $this->getMock(EventDispatcher::class); |
||
29 | |||
30 | $symfonyDispatcher |
||
31 | ->expects($this->once()) |
||
32 | ->method('dispatch') |
||
33 | ->with( |
||
34 | get_class($domainEvent), |
||
35 | $this->isInstanceOf(SymfonyEvent::class) |
||
36 | ) |
||
37 | ; |
||
38 | |||
39 | $dispatcher = new Dispatcher($symfonyDispatcher); |
||
40 | |||
41 | $dispatcher->dispatch($domainEvent); |
||
42 | } |
||
43 | } |