| Conditions | 1 |
| Paths | 1 |
| Total Lines | 18 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 15 | public function test() |
||
| 16 | { |
||
| 17 | $this->assertCount(0, $this->subscriptions); |
||
|
|
|||
| 18 | $this->assertCount(0, $this->registrations); |
||
| 19 | $result = $this->dispatch('module.bootstrap'); |
||
| 20 | |||
| 21 | // web.register was called |
||
| 22 | $this->assertCount(1, $this->registrations); |
||
| 23 | |||
| 24 | // event.subscribe was called |
||
| 25 | $this->assertCount(2, $this->subscriptions); |
||
| 26 | $this->assertSame($this->subscriptions[0]->event, 'person.created'); |
||
| 27 | $this->assertSame($this->subscriptions[1]->event, 'person.person.*'); |
||
| 28 | $this->assertSame($this->subscriptions[0]->service, 'test'); |
||
| 29 | |||
| 30 | // cache exists |
||
| 31 | $this->dispatch('module.bootstrap'); |
||
| 32 | } |
||
| 33 | |||
| 47 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: