Skip to content

codeception + enqueue/async-event-dispatcher = Fatal error #1220

@mihas2

Description

@mihas2

i use codeception 4.1 + codeception/module-symfony 2.0 + enqueue/async-event-dispatcher 0.10.8 + symfony 5.3 and when running tests I get this error
Fatal error: Declaration of Enqueue\AsyncEventDispatcher\AsyncEventDispatcher::dispatch($event, $eventName = null) must be compatible with Symfony\Component\EventDispatcher\EventDispatcher::dispatch(object $event, ?string $eventName = null): object in /var/www/ms-notifier/vendor/enqueue/async-event-dispatcher/AsyncEventDispatcher.php on line 16

I think it's all about the module enqueue/async-event-dispatcher, which in one version tries to support different versions of symfony
if (class_exists(Event::class)) { /** * Symfony < 5.0. */ ... } else { /** * Symfony >= 5.0. */ ... }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions