Fully Qualified Name: | Zend\EventManager\Test\EventListenerIntrospectionTrait |
Trait providing utility methods and assertions for use in PHPUnit test cases.
This trait may be composed into a test case, and provides:
Some functionality in this trait duplicates functionality present in the version 2 EventManagerInterface and/or EventManager implementation, but abstracts that functionality for use in v3. As such, components or code that is testing for listener registration should use the methods in this trait to ensure tests are forwards-compatible between zend-eventmanager versions.
Name | Description | Defined By |
---|---|---|
traverseListeners() | Generator for traversing listeners in priority order. | EventListenerIntrospectionTrait |
Generator for traversing listeners in priority order.
Parameter Name | Type | Description |
---|---|---|
$listeners | array | |
$withPriority | bool | When |
$queue |
Returns: