Skip to content

Commit f62d40c

Browse files
[EventDispatcher] swap arguments of dispatch() to allow registering events by FQCN
1 parent c558191 commit f62d40c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Tests/Form/EventListener/MergeDoctrineCollectionListenerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public function testOnSubmitDoNothing()
6363
$submittedData = ['test'];
6464
$event = new FormEvent($this->getForm(), $submittedData);
6565

66-
$this->dispatcher->dispatch(FormEvents::SUBMIT, $event);
66+
$this->dispatcher->dispatch($event, FormEvents::SUBMIT);
6767

6868
$this->assertTrue($this->collection->contains('test'));
6969
$this->assertSame(1, $this->collection->count());
@@ -74,7 +74,7 @@ public function testOnSubmitNullClearCollection()
7474
$submittedData = [];
7575
$event = new FormEvent($this->getForm(), $submittedData);
7676

77-
$this->dispatcher->dispatch(FormEvents::SUBMIT, $event);
77+
$this->dispatcher->dispatch($event, FormEvents::SUBMIT);
7878

7979
$this->assertTrue($this->collection->isEmpty());
8080
}

0 commit comments

Comments
 (0)